This command extracts a selected subset of data from a database in the form of an XML file.
Notes:
- The above diagram is intended primarily as a reference for the command parameters. The command file or script provided for this command and listed in Configuring Loader package commands and scripts acts as a wrapper to the actual Java command and accepts the same parameters; therefore, it is recommended that you use the command file or script rather than invoke the Java command directly.
- Filenames specified as parameters for this command can be preceded by relative or absolute paths.
Parameter values
- -filter
- Name of the extraction-filter file
- -outfile
- Name for the output XML file where the extracted data will be stored
- -dbname
Name of the database from which data is being extracted
This is the database name as displayed in the relational database directory (WRKRDBDIRE)
- -dbuser
Database user name for the database from which data is being extracted
This is usually the same as the instance user name
- -dbpwd
- Password associated with the user name for the database from which data is being extracted
- -customizer
- Name of the customizer property file to be used. The default file is:
DB2ConnectionCustomizer.properties
ISeries_EXTWCSDTA_Customizer.properties
If you have configured your instance to use the toolbox driver, then use the Toolbox_EXTWCSDTA_Customizer customizer file provided for the toolbox driver. You must also specify the hostname for the -dbname parameter. The following is an example of invoking the massextract.sh script:./massextract.sh -dbname MY.HOSTNAME.CA -dbuser instance -dbpwd mypass -filter /path/filter.xml -outfile /path/file.xml -customizer Toolbox_EXTWCSDTA_Customizer
The customizer property file can be specified as shown in the following example:
-customizer WC_installdir/my_directory/file_name.properties
-customizer WC_installdir/my_directory/file_name
-customizer WC_userdir/my_directory/file_name.properties
-customizer WC_userdir/my_directory/file_name
If this file exists in the current directory, the same file can be specified as shown in the following example:
-customizer file_name.properties
If this file exists in a directory specified in the classpath system-environment variable, the same file can be specified as shown in the following example:
-customizer file_name
where, my_directory is a user define directory and file_name is the name of the property file that you want to use.
- -schemaname
- Name of the database schema from which data is being extracted. This parameter is optional. If this parameter is not specified when running the command, the command looks for a name=value pair in the customizer property file that specifies the value of SchemaName. If this pair is present in the property file, the command uses the value specified. If neither a command-line nor a property-file specification for this parameter exists, the command defaults to the schema name of the table in the database.
Extract command
Parameter values
- -filter
- Name of the extraction-filter file
- -outfile
- Name for the output XML file where the extracted data will be stored
- -dbname
- Name of the database from which data is being extracted
- -dbuser
- Database user name for the database from which data is being extracted
- -dbpwd
- Password associated with the user name for the database from which data is being extracted
- -customizer
- Name of the customizer property file to be used. The default file is:
DB2ConnectionCustomizer.properties The customizer property file can be specified as shown in the following example: -customizerWC_installdir\my_directory\file_name.properties
If this file exists in a directory specified in the classpath system-environment variable, the same file can be specified as shown in the following example:
-customizer file_name
where, my_directory is a user define directory and file_name is the name of the property file that you want to use.
- -schemaname
- Name of the database schema from which data is being extracted. This parameter is optional. If this parameter is not specified when running the command, the command looks for a name=value pair in the customizer property file that specifies the value of SchemaName. If this pair is present in the property file, the command uses the value specified. If neither a command-line nor a property-file specification for this parameter exists, the command defaults to the schema name of the table in the database.