Results 1 to 5 of 5
  1. #1
    5 Star Lounger
    Join Date
    Feb 2001
    Location
    Youngstown, Ohio, USA
    Posts
    705
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Command line compacting (2000 SR1)

    <img src=/S/help.gif border=0 alt=help width=23 height=15> I have to work with an AS400 query-created database to integrate newly-available data into existing databases. One significant problem is the file size, massively bloated at 5- to 10-times its compacted size. The new data file is to be transmitted to our remote locations, so transmitting a 1.5MB file is much more preferable than transmitting a 15MB file, especially when there will be about 30 files to be sent each time.

    I looked at JetComp for a possible solution, but it does not seem to support command line parameters. Is there another utility available that can be run from a command prompt or through a batch file?

  2. #2
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Command line compacting (2000 SR1)

    Access itself has a command line option to compact the database. It is "/compact" on Access97, and I think it is "/repair" on Access2000 and above (which does both a compact and repair, although the "/compact" may also have been retained form compatibility).
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  3. #3
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Command line compacting (2000 SR1)

    The command line option is /compact in Access 2000 and 2002 too.

    This is the complete command line for Access 2000

    "C:Program FilesMicrosoft OfficeOfficeMSACCESS.EXE" "%1" /compact

    and for Access 2002:

    "C:Program FilesMicrosoft OfficeOffice10MSACCESS.EXE" "%1" /compact

    assuming that Office has been installed in the default location.

  4. #4
    5 Star Lounger
    Join Date
    Feb 2001
    Location
    Youngstown, Ohio, USA
    Posts
    705
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Command line compacting (2000 SR1)

    The /compact switch did the trick! Access opened, compacted, and closed very nicely, leaving the distribution-sized file ready to go. <img src=/S/groovin.gif border=0 alt=groovin width=21 height=21> Now to just get this built directly into the file generation process, or set up in a batch file to run before the distribution. Either way, clearing this hurdle makes the rest of the project much more practicable.

  5. #5
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Command line compacting (2000 SR1)

    Yeah, I had it backwards. The /compact now does both compact & repair. The /repair has been retained for backward compatibility.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

Posting Permissions

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