Re: dba_delete() problems

From: Date: Tue, 04 Jun 2002 06:38:36 +0000
Subject: Re: dba_delete() problems
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-19592@lists.php.net to get a copy of this message
In article <20020602080642.61605.qmail@pb1.pair.com>, oceanwave@linkline.com says... > Hello all, > > I've got a bit of a problem at the moment. I'm using the dba_ functions to > do some simple database access, and I have the need to delete some items > from the database from time to time. When dba_delete() is called, it returns > true, indicating that the key/value pair was deleted. After making the > deletions, dba_sync() is called. The problem is, the database size never > decreases no matter how much you delete (even if you remove every item). On > examination of the .dbm files in text editor, I found that all the data from > every key/value pair was still there, and hadn't been removed as I wanted it > to. This is extremely bad for the database, because it grows constantly with > no way to decrease the size other than flat out deleting it, which I don't > want to do. Am I doing something wrong with deleting the keys, or is this an > issue with dba? > > Notes: I'm using Apache 1.3.24 and PHP 4.2.1 on Windows XP Professional. The > database is accessed using the db3 handler. > > Thank you in advance for any replies, > Steve I don't know ththe Berlely style db app, but what does dba_optimize do? That may be analogous to DBase's Pack function which tidies up empty entries? -- David Robley Temporary Kiwi! Quod subigo farinam

« previous php.db (#19592) next »