Results 1 to 2 of 2
  1. #1
    New Lounger
    Join Date
    Feb 2001
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Auto-compacting? (97 SR2b)

    Hi Lounge gurus,

    Is it possible to compact a database from code? I have an app that imports a CSV file full of data (about 5000 records per month) to a temporary table. The end result of a few queries is that a few totals are appended to a permanent table, and the temp table is deleted.

    This bloats the database and I would like to compact it on close.

    Can it be done?

    TIA
    JP

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Auto-compacting? (97 SR2b)

    You could built an import spec if the file is always the same shape (or you may already have one) and then use that spec to link the text file instead of importing it. That would virtually eliminate the need to compact after you work with the data. Compacting from code is fairly complicated and prone to breakage. Compact on close is actually a built-in feature in Access 2000.
    Charlotte

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •