DB Alias Tab – Sybase ASE, Load Request Editor

Use the DB Alias tab to define the specific parameters needed to perform the Load Process for the Sybase ASE loader.

Load Request Editor with DB Alias - Sybase ASE as the active tab. The elements of the DB Alias - Sybase ASE tab are described as follows.

Mode

Insert
Insert the rows from the Source File into the destination tables. If the primary key values match, duplicate rows are discarded or inserted into the error file (if specified).
Replace
Clear and replace all existing rows in the destination tables with the rows from the Source File.

Options

Perform Load
Select this check box to run the loader automatically after file conversion processing is complete. If you clear this check box, the Load Process prepares the data in the appropriate format and creates the BAT file to run the loader, but does not initiate the loader. To run the loader, edit the BAT file to include the proper password information and then run the BAT file.
Note: Since Sybase ASE does not accept a Replace operand for a load request, make sure the tables are empty before you run the BAT file.
Delete files if Successful
Select this check box to delete the data files after the loader completes successfully. If you select this check box, the Fast Load Confirmation feature is unavailable.
Note: Fast Load Confirmation reduces processing time when you run a Load Request that has run before. See Process a Load Request for detailed information.
Delete files if Failure
Select this check box to delete the data files if the loader does not complete successfully. If you select this check box, the Fast Load Confirmation feature is unavailable.
Load When Source Is Empty
Select this check box to perform the load if a table to be loaded contains no rows. If you do not select this check box, any tables in the Archive File containing no rows will be skipped in the load phase. Using load with an empty source table deletes rows from the target table, resulting in a clean test environment.

Disable Triggers

For Sybase ASE (Version 12 or later), you can disable triggers:

Always
Select this option to disable all database triggers for the Load Process, re-enabling the triggers after the process completes.
Never
Select this option to execute all database triggers during the Load Process.
Prompt
Select this option to selectively disable database triggers during the Load Process and selectively re‑enable triggers when the process is complete.

Error File Options

Create
Select this check box to instruct the loader to create a discard file to use during the Load Process.
Max Errors
Enter the number of rows up to 999999999, that the loader can discard because of errors during the Load Process. The process stops when the specified number of rows is discarded.
  • To end the process if a single row is discarded, specify 1 as the maximum.
  • To set no limit to the number of rows that can be discarded, specify zero (0) or leave blank.

Additional Loader Parameters

You can augment the loader arguments created automatically by Archive with additional loader parameters, if necessary. The additional parameters you create are appended to the list created by Archive, but are not validated by Archive prior to starting the loader. Refer to Sybase ASE documentation for valid operands. If additional loader parameters are forced from within Product Options, you cannot modify them. Refer to the Installation and Configuration Guide.

Disable Constraints

Note: Options for disabling referential integrity constraints are applicable to SQL Server Version 7.0 or later.
Never
Select this option if you do not want to disable referential integrity constraints for the loader. When this option is selected, a warning message displays when you run the loader.
Constraint Non-Disablement Warning dialog, which is displayed if referential integrity constraints are not disabled.
Always
Select this option to disable constraints during the Load Process and then re-enable the constraints after the process completes.
Prompt
Select this option to display the Disabling Trigger/Constraint Confirmation dialog. This dialog displays a list of tables with all associated constraints. You can right-click to enable or disable constraints during the Load Process for each table. You can also select whether to enable or disable the constraints after the Load Process completes.
Note: Options to disable triggers and constraints apply only when you select the Perform Load option.

The Disabling Trigger/Constraint Confirmation dialog displays the list of tables in the Load Process and tabs that contain the corresponding database triggers and referential integrity constraints for each table.

A Focus Arrow in the first grid column indicates the table for which triggers and constraints are listed. To display the corresponding triggers and constraints for a different table, click a Focus Arrow grid cell to reposition the arrow, or use the up/down arrows on your keyboard.

Disabling Trigger/Constraint Confirmation dialog

Right-click the Status During Process column to select to enable or disable the corresponding trigger or constraint during the Load Process.

Right-click the Status After Process column to select whether to enable or disable the corresponding trigger or constraint after the Load Process completes.

Work path for interim files

Specify a default directory path for storing the temporary loader files.

Load — Table Partition Mapping

If you want to store archived data in a specific partition, you must pass the appropriate partition name when you run the Load process. (Contact your DBA for the appropriate partition names.) A Table Partition Mapping dialog is used to map the Destination Table to a Sybase Partition.

This dialog is displayed by clicking Tools > Edit Partition Map.

Table Partition Mapping dialog

The Table Partition Mapping dialog includes a tab for each Sybase DB Alias in the subject Optim Load Request. The Destination Table column lists every table mapped within the Table Map Editor, and the Partition column is used to specify the Sybase partition identifier or name for each table. You can specify one partition name only for each table.

Note: Make sure the archive file contains data only for the targeted partition, otherwise you will receive an error from the Sybase loader.

Say, for example, you created a table called “my_publishers” that is partitioned by list, according to the values in the state column, as indicated as follows. (Certain entries are shown in bold for emphasis only.)

create table my_publishers
 (pub_id char(4) not null,
  pub_name varchar(40) null,
  city varchar(20) null,
  state char(2) null)
 partition by list (state)
(west values ('CA', 'OR', 'WA') on seg1,
 east values ('NY', 'MA') on seg2)

If your archive file contains data for three states — California (CA), Oregon (OR), and Washington (WA) — you would specify west as the Partition, as shown in the earlier Table Partition Mapping example. Conversely, if your archive file contained data for two states — New York (NY) and Massachusetts (MA) — you would specify east as the Partition.

After you specify the appropriate partition name(s), close the Table Partition Mapping dialog to redisplay the previous dialog.