How to clear memory usage after executing queries ?

From: Paul fpvt2 (Paulfpvt2_at_discussions.microsoft.com)
Date: 12/23/04


Date: Thu, 23 Dec 2004 07:35:03 -0800

We have a SQL Server 2000 database that has about 10 million records. The
database has 1 table, and the table has 3 columns.
CREATE TABLE [dbo].[Packet] (
[PACKET_TIME] [datetime] NOT NULL ,
[PACKET_CONTRACT] [varchar] (8) NOT NULL ,
[PACKET_DATA] [varchar] (2000) NOT NULL )

I have a clustered indexed for column ([PACKET_CONTRACT],[PACKET_TIME]). I
found this index execute the query that I want the fastest.

When I query the database, for example:
-select distinct(packet_contract) from packet (Returns 600 records)
-select packet_data from packet where packet_time >= dateadd(hour, -96,
getdate()) and packet_contract = 'ABCD' (returns 135,000 records)

the memory usage for SQL Server shot up from 50,000 K to 275,000 K.
The database currently has about 4 million records.

I tried the following statements, but the memory is still not cleared up:
-DBCC DROPCLEANBUFFERS
-dbcc freeproccache

The only way to clear up the memory usage is by stopping SQL Server Service
Manager.
How can I clear up the memory usage after executing a query without stopping
SQL Server Service Manager ?
Thanks a lot.



Relevant Pages

  • RE: full-text search failed with one million of key words (Sqlserv
    ... Research with "toto" was just a test. ... In real life, my database contains ... for only one book) And the table i want to query looks like this: ... I have to make big tests with sql server 2005 express (i'm waiting credits ...
    (microsoft.public.sqlserver.fulltext)
  • Re: Error 25081: Incorrectly generating identities after a merge
    ... database similarly to SQL Server CE Replication. ... On the SQL Server 2000 database with replicated tables from the original ... The I synchronized that database and ran the same query: ... >> synchronization. ...
    (microsoft.public.sqlserver.ce)
  • Re: Looking for a professional SQL programmer for a small job
    ... Pro SQL Server 2000 Database Design - ... I have two queries to build and while I know my way around SQL, ... >> One is a seach query that pull rental properties from a database based on ...
    (microsoft.public.sqlserver.programming)
  • Re: Using a worksheet as a table in an SQL query
    ... I'll probably just dump the SQL Server data to a spreadsheet and join the two spreadsheets. ... You could use Access to link to both sources and create a crosstab query. ... There are ways to enter the data into their database via the application, but it would require them to go to many different windows instead of being able to enter the data all on one screen. ... There is not a great deal of data they would enter on the spreadsheet, but I'm not sure how slow that would make the query. ...
    (microsoft.public.excel.programming)
  • Re: Issue with a table that is 75%-80% of the database size
    ... SQL Server 2000 does not support table partitioning. ... Have you tried database differential backup? ... your query response time and backup time. ...
    (microsoft.public.sqlserver.server)

Loading