Click here to Skip to main content
15,894,343 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi,

My .NET 2.0 Framework app gives error

Exception of type 'System.OutOfMemoryException' was thrown.

Target :- mscorelib.

this happens when i do the following acvtivity
1) save a transaction of 990+ inserts to DB . saved sucessfully
2) Issue occurs when i do the next save transaction .

I was checking how to fix this issue ,
there is a fix for this issue from Microsoft as part of KB917495 ,
http://archive.msdn.microsoft.com/KB917495 .

I am runing my app on windows 7.

Any idea how we can fix this issue.

Thanks,
srastogi
Posted
Comments
Sergey Alexandrovich Kryukov 20-Sep-13 13:33pm    
1) Not enough information, 2) There is no such thing as miracle. All systems may face some memory limitations sooner or later. Well, look is the memory usage is optimal or not, look for memory leaks (yes, even managed memory can be a subject of memory leak).
—SA
srastogi85 20-Sep-13 13:59pm    
Hi Sergey,

There is no memory leak in the code written , we checked it , i wanted to have info have anyone encountered similar issue and what was done to resolve , did this hotfix from microsoft worked

1 solution

There's an old saying : "if it hurts when you do something, then don't do it".

Do your transactions in smaller chunks of say 100 inserts for example.
 
Share this answer
 
Comments
srastogi85 20-Sep-13 12:38pm    
Its an existing application which works fine when inserts are less , I cannot change logic at this moment , thanks for reply
Sergey Alexandrovich Kryukov 20-Sep-13 13:31pm    
I just like it, a 5.
—SA
Mehdi Gholam 20-Sep-13 14:35pm    
:)
CPallini 20-Sep-13 13:42pm    
I have to agree again with Sergey, my 5.
Mehdi Gholam 20-Sep-13 14:35pm    
:)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900