compact db. Help!!! 
Author Message
 compact db. Help!!!

Hi ,

Does anyone know  why the following code doesn't work. I want to compact a
MSACESS database(olddb.mdb)  with SQLConfigDataSource function call, but it
always return 0.

///////////////////////////////////////
BOOL fCreated;
fCreated = SQLConfigDataSource(NULL,
                        ODBC_CONFIG_DSN,
                       "Microsoft Access Driver (*.mdb)",
                       "COMPACT_DB=D:\\olddb.mdb;D:\\newdb.mdb\0" );
////////////////////////////////////////

Thanks
Leo



Sun, 04 Feb 2001 03:00:00 GMT  
 compact db. Help!!!
Have you tried separating database file names with an space, instead of ';'?
(that's the way it's specified on the docs).

Also try calling SQLInstallerError() to see what's causing the error.

Tomas Restrepo

http://www.geocities.com/SiliconValley/Heights/3401


Quote:
>Hi ,

>Does anyone know  why the following code doesn't work. I want to compact a
>MSACESS database(olddb.mdb)  with SQLConfigDataSource function call, but it
>always return 0.

>///////////////////////////////////////
>BOOL fCreated;
>fCreated = SQLConfigDataSource(NULL,
>                        ODBC_CONFIG_DSN,
>                       "Microsoft Access Driver (*.mdb)",
>                       "COMPACT_DB=D:\\olddb.mdb;D:\\newdb.mdb\0" );
>////////////////////////////////////////

>Thanks
>Leo



Sun, 04 Feb 2001 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Compact DB or repair DB

2. Compacting Access-DB with MFC

3. Compact a Jet db

4. Compacting an Access2002 db with ADO

5. Compacting a Jet database via OLE DB?

6. repairing and compacting a password protected ODBC Access db

7. ADO and DB compact, same source/dest

8. Compacting Access Db using SQLConfigDataSource

9. Compacting an Access db using ODBC is possible!!

10. Compacting DB

11. HELP! : a linker problem with compact memory model

12. HELP! : a linker problem with compact memory model

 

 
Powered by phpBB® Forum Software