MultiThread: write multiple tables in the file geodatabase at same time?

712
2
12-16-2016 06:43 AM
springzhang
New Contributor II

I used C# and ArcObjects to write 6 output tables in the same workspace. To improve the performance, I tried to do parallelization, each thread writing one table . Codes were pasted below.

Parallel.For(0, tableCount, k=>
{

      //write kth table

      writeTable(k);

}

But I got the error "can not acquire the lock....". It seems that workspace did not support multiple writing at the same time. Is there any other solutions? 

0 Kudos
2 Replies
nicogis
MVP Frequent Contributor
0 Kudos
springzhang
New Contributor II

Thanks!

Finally, I wrote the tables as txt files, which allowed me to do the writing at the same time. 

0 Kudos