473,583 Members | 2,875 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

SQLBulkCopy memory leak..

Hi,
I need to insert a large amount of records pretty frequently through
my application. The quickest way to achive this seems to be
SQLBulkcopy class. I have implemented the solution using the bulkcopy
class and works quite well except for one problem.
It doesn seem to release the memory it uses. I have found that the
memory used increases quite rapidly when using this class, further
more the memory is not collected even when I close and dispose the
SQLBulkcopy instance.
I have verified this finding running the application after commenting
the SQLBulkcopy realated code, the memory utilization is normal. But
when I uncomment the SQLbulkcopy code, the issue arises.
please help.
Aug 25 '08 #1
2 2343
Can we see any of the SqlBulkCopy code? In particular, I wonder if
you've hooked up some events (SqlRowsCopied, etc) in a way that is
keeping it alive...

Marc
Aug 25 '08 #2
On Aug 25, 5:17*am, Amar <amarjeetlokha. ..@gmail.comwro te:
Hi,
I need to insert a large amount of records pretty frequently through
my application. The quickest way to achive this seems to be
SQLBulkcopy class. I have implemented the solution using the bulkcopy
class *and works quite well except for one problem.
It doesn seem to release the memory it uses. I have found that the
memory used increases quite rapidly when using this class, further
more the memory is not collected even when I close and dispose the
SQLBulkcopy instance.
I have verified this finding running the application after commenting
the SQLBulkcopy realated code, the memory utilization is normal. But
when I uncomment the SQLbulkcopy code, the issue arises.
please help.
post some code. I have used it before and I have never found an issue
with memory consuption
Aug 25 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
3397
by: ranjeet.gupta | last post by:
Dear All Is the Root Cause of the Memory corruption is the Memory leak, ?? suppose If in the code there is Memory leak, Do this may lead to the Memory Corruption while executing the program ? In nut shell, what is/are the realtion/s between the Memory Leak and Memory Corruption. Juts Theoritical Assumtion below:
17
4786
by: José Joye | last post by:
Hi, I have implemented a Service that is responsible for getting messages from a MS MQ located on a remote machine. I'm getting memory leak from time to time (???). In some situation, it is easier to reproduce (e.g.: remote machine not available). After about 1 day, I get a usage of 300MB of memory. I have used .NET Memory Profiler tool to...
20
8072
by: jeevankodali | last post by:
Hi I have an .Net application which processes thousands of Xml nodes each day and for each node I am using around 30-40 Regex matches to see if they satisfy some conditions are not. These Regex matches are called within a loop (like if or for). E.g. for(int i = 0; i < 10; i++) { Regex r = new Regex();
23
4528
by: James | last post by:
The following code will create memory leaks!!! using System; using System.Diagnostics; using System.Data; using System.Data.SqlClient; namespace MemoryLeak
3
5303
by: Jim Land | last post by:
Jack Slocum claims here http://www.jackslocum.com/yui/2006/10/02/3-easy-steps-to-avoid-javascript- memory-leaks/ that "almost every site you visit that uses JavaScript is leaking memory". Anybody know anything about this? Does *Javascript* leak memeory, or does the *browser* leak memory?
5
14759
by: TheSteph | last post by:
Using : MS-SQL 2005 / .NET 2.0 / VS2005 I have two server with the same database def but different data. I would like to import data from Server2.TableA to Server1.TableA. If a row doesn't exists on Server1.TableA, it should be added; if the data already exists it should be updated. I have to write a C# application do this operation on...
22
9326
by: Peter | last post by:
I am using VS2008. I have a Windows Service application which creates Crystal Reports. This is a multi theaded application which can run several reports at one time. My problem - there is a memory leak someplace. I can not detect the memory leak by running several reports by hand, but when I run tha app as a servrice and process few...
1
3304
by: Sergey Zenyuk | last post by:
In VB.net windows application I use following code implementing SqlBulkCopy import: Using connODBC As New OdbcConnection(ConnStrODBC) connODBC.Open() Dim dbcmd As New OdbcCommand(String. Format("select * from {0}", TableName), connODBC) dbcmd.CommandTimeout = SQL_TIMEOUT bulkcopy.WriteToServer(dbcmd.ExecuteReader()) connODBC.Close()...
3
2306
by: SteveB | last post by:
Hi All, Using the SQLBulkCopy for big CSV files consumes almost all the memory in the computer. I found how to resolve this problem while google that, but no code was added. The person claimed that he flushed all temporary working tables every 100K records to avoid filling up the memory. If someone dealt with this please write down the...
0
7888
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7811
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
8314
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7922
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
8185
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5366
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3836
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1416
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1147
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.