--- "Babu, Lokesh" <[EMAIL PROTECTED]> wrote:
> Does anybody knows the exact code, a little hack where can I free up the
> memory, I don't want it to use it for future requests.
> 
> Even drop table consumes memory. :-(.
> 
> If we are doing in-memory database operation, why do we want to maintain the
> free'd memory pages?

On Linux using sqlite 3.4.1:

-- start sqlite3 shell

-- 2m VIRT, 1m RES

pragma temp_store=memory;
CREATE TABLE abc(a,b,c);
INSERT INTO "abc" VALUES(5400,'some dumb phrase to fill stuff',-345.7);
INSERT INTO "abc" VALUES(-1234,'the quick brown fox', 20394203492340.5);
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;
insert into abc select * from abc;

-- 167m VIRT, 166m RES

delete from abc where a != b;

-- 200m VIRT, 199m RES peak usage during delete

-- 167m VIRT, 166m RES after delete

vacuum;

-- 18m VIRT, 1m RES

Are you seeing different results?



       
____________________________________________________________________________________Ready
 for the edge of your seat? 
Check out tonight's top picks on Yahoo! TV. 
http://tv.yahoo.com/

-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to