Hello RohitPatel9999,

Tuesday, June 13, 2006, 10:43:23 AM, you wrote:


R> Hi SQLiteUsers

R> Developing MFC Application (Small Business Accounting Application)
R> (developed using Visual Studio) 
R> - App will run on Windows 98/2000 
R> - App uses SQLite database files for storage of data
R> - It will have one database for each company accounts/info. So if accounts
R> of 10 companies, then info will be in 10 different SQLite DB files.
R> - All Database files on same disk.
R> - User of App may create more company file for accounts of another company.
R> - User of App may open any existing company file and enter/modify
R> transactions through different GUI screens.
R> - User closes file and may open another company file and enter/modify
R> transactions through different GUI screens.


R> After using such application, all used SQLite DB files gets fragmented.


R> How to avoid such fragmentation ?


R> Is there any feature, to pre-allocate disk-space to SQLite database file so
R> that initially some free space will be allocated to new file ? 
R> Is there any feature, so that when database file gets filled, everytime
R> automatically increment file size by say 25% or 40% of size ?

R> FYI: Such pre-allocation of space and automatic incrementing file size is
R> provided for Database files in SQLServer, Oracle etc.

R> Rohit
R> --
R> View this message in context:
R> 
http://www.nabble.com/Avoiding-Fragmentation-of-SQLite-database-file-----t1780629.html#a4848030
R> Sent from the SQLite forum at Nabble.com.


I'd think allocating the space for the file, then copying the SQLite
DB to this new file, renaming the old and renaming the new would
defragment the file too.

As an experiment, I copied a 5G db from one filename to another and it
changed from 6700 fragments to 1.


-- 
Best regards,
 Teg                            mailto:[EMAIL PROTECTED]

Reply via email to