iqunload is a command line utility for SAP Sybase IQ 12.6 and 12.7 database migration. iqunload re-creates the legacy catalog on the new database catalog in the current installation.
iqunload [ options ] directory [ @data ]
data:[ environment variable | file ]
iqunload takes one or more parameters.
Specify an -au argument to start iqunload in migration mode. or -n argument, but not both.
If not specified, the default new main store is a file system file called new_main_store.iq
iqunload –au –c “UID=DBA;PWD=SQL;DBF=/mydevice/test_dir/test2.db”
ENG=myserver_test2” –r “D:\test\unload_dir\test2_reload.sql”
iqunload –au –c "UID=DBA;PWD=SQL;DBF=asiqdemo.db" -ms_filename \\\\.\\PhysicalDrive2
iqunload has two working modes: schema unload and migration.
Schema Unload Mode
iqunload requires an -n argument to start in schema unload mode. Schema unload mode unloads a 12.6 ESD #11 or 12.7 ESD #5 database schema, and generates a script (reload.sql) that can re-create the schema for a database in a current version of the software. A -c argument is required for connection parameters:
iqunload -n -c "UID=DBA;PWD=SQL;ENG=my_engine;DBN=my_dbname"
Schema unload mode re-creates the schema, but does not migrate data. To migrate data, extract the legacy data and load the new database.
Migration Mode
Insufficient cache memory causes migration errors. iqunload uses default values for various cache sizes (catalog cache, main buffer cache, temp cache). If the legacy database requires higher cache values, use the –ch and -cl options as part of the START connection parameter to increase the cache size.
During database migration, the server creates a message file (*.iqmsg.R) as it reloads the generated schema. This file is normally deleted as part of a cleanup operation for successful migrations. If the migration fails during the reload stage, cleanup does not occur, and *.iqmsg.R remains in the unload directory. *.iqmsg.R may contain information that can help solve your migration problems.
iqunload writes some temporary files to the %IQTMP16% directory. If you set the %IQTMP16% environment variable, set it to a valid directory name.
Users with wide tables (large numbers of column/null values) should not decrease the catalog store page size for database migration.
If the legacy database contains invalid views, SAP Sybase IQ completes the migration but issues warnings. A warning may occur, for example, if the tables involved in a view are dropped.
If the legacy database is encrypted, use the DBKEY connection parameter to provide the encryption key. The migrated database uses the same encryption key.
DBA