Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 .NET Inside SQL Server (2005)
 Releasing Memory

Author  Topic 

afitch
Starting Member

7 Posts

Posted - 2008-05-13 : 23:18:36
My application is a VB.net client server app with SQL Express on the backend, for some reason both my SQL server and Application continue to increase their memory usage over time, every procedure utilizes the close method of the sqlconnection and then sets the sqlconnection to nothing. Is there anything else I should be doing to close the connection and prevent this memory increase?

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-05-14 : 13:14:30
It is normal for SQL Server to increase the amount of memory that it uses. SQL Server is a memory hog. This is why SQL Server should be on a dedicated server.

The only way to stop SQL Server from grabbing more memory is by setting the max memory setting. But this could cause a performance problem for you.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Database maintenance routines:
http://weblogs.sqlteam.com/tarad/archive/2004/07/02/1705.aspx
Go to Top of Page

afitch
Starting Member

7 Posts

Posted - 2008-05-14 : 13:50:09
I understand that it is normal for sqlserver to take more memory, but I don't think that my application should be taking a corresponding amount of extra memory. Also, the querying that is being done is on the same three tables so I wouldn't think that would force sql to keep taking additional memory since it should already have the data from those tables cached, that is why I am wondering if there is some other process that I should be using to clear the query from the server which would in turn allow my application to release the memory for that connection. Everything I have read says to just close the sqlconnection object and dispose of it which I am doing, but it still seems to be causing an increase in memory usage over time.
Go to Top of Page
   

- Advertisement -