C# Application process hangs after some time
Posted
by Chris
on Stack Overflow
See other posts from Stack Overflow
or by Chris
Published on 2010-04-07T12:04:28Z
Indexed on
2010/04/07
12:13 UTC
Read the original article
Hit count: 199
Hi,
I implemented a simple C# application which inserts about 350000 records into the database. This used to work well and the process took approximately 20 minutes.
I created a progress bar which lets you know approximately the progress of the records insertion. When the progress bar reaches about 75% it stops progressing. I have to manually terminate the program as the process doesn't seem to complete. If I use less data (like 10000), the progress bar finishes and the process is completed. However when I try to insert all the records, this won't happen any more.
Note that if I wait longer to terminate the program manually, more records would have been inserted. For example, if I terminate the program after 15 minutes, 200000 records are inserted, whereas if I terminate the program after 20 minutes, 250000 records are inserted.
This program is using a single thread. In face I can't do anything else until the process is complete. Does this have anything to do with threading or processes?
Any feedback will be greatly appreciated.
Thanks.
© Stack Overflow or respective owner