contents.gifindex.gif

Examples: Generic_SQL_Export Function

Example 1

Generic_SQL_Export ("SELECT DISTINCTROW ALIAS.* FROM ALIAS,AP FEEDS, ALIAS.DBF,””, dBase III, RENAME)

Example 1 exports to the file ALIAS.DBF in the file group identified by AP Feeds using dBASE III format. If ALIAS.DBF already exists, the old ALIAS.DBF will be renamed to ALIAS.000. If ALIAS.000 already exists, the old ALIAS.DBF will be renamed to ALIAS.001, etc.

Example 2

Generic_SQL_Export ("SELECT DISTINCTROW ALIAS.* FROM ALIAS,AP Feeds, ALIAS.DBF,””, dBase III, RENAME DBK)

Example 2 exports to the file ALIAS.DBF using dBASE III format. If ALIAS.DBF already exists, the old ALIAS.DBF will be renamed to ALIAS.DBK. If ALIAS.DBK already exists, it will be overwritten.

Example 3

Generic_SQL_Export ("SELECT DISTINCTROW ALIAS.* FROM ALIAS, AP Feeds, TRAXMAIN.MDB,Alias, Microsoft Access, RenameTable Alias Save)

Example 3 creates a table Alias in file TRAXMAIN.MDB. If TRAXMAIN.MDB does not exist, it will be created. If table Alias already exists, it will be renamed to Alias Save. If table Alias Save already exists, it will be overwritten.

Example 4

Generic_SQL_Export ("SELECT DISTINCTROW ALIAS.* FROM ALIAS, AP Feeds, BACKUP.MDB,Alias, Microsoft Access,Rename MBK)

Example 4 creates an Access database BACKUP.MDB and create a table Alias in it. If BACKUP.MDB already exists, it will be renamed to BACKUP.MBK. If BACKUP.MBK already exists, it will be overwritten.

Example 5

Generic_SQL_Export ("SELECT DISTINCTROW ALIAS.* FROM ALIAS, AP Feeds, TRAXMAIN.MDB,Alias, Microsoft Access, FailTable)

Example 5 creates a table Alias in file TRAXMAIN.MDB. If TRAXMAIN.MDB does not exist, it will be created. If table Alias already exists, Generic_SQL_Export fails and returns Null.

Example 6

Generic_SQL_Export ("SELECT DISTINCTROW ALIAS.* FROM ALIAS, AP Feeds, ALIAS.XLS,””, Excel, Rename)

Example 6 creates an Excel 5.0 spreadsheet ALIAS.XLS. If ALIAS.XLS already exists, it will be renamed to ALIAS.000. If ALIAS.000 already exists, it will be renamed to ALIAS.001, etc.