To capture changes from an Adabas database, you must create a relational
table that maps to that database. You can also create a view on the table.
Use the New Adabas Table wizard to create a table and a view.
Before you begin
- Configure the data server where you plan to run the correlation service
that will process change data from your Adabas database.
- Create a metadata catalog.
- Decide which data structures to map in your database.
- Configure a connection between the data server and your Adabas database.
- If you want to use Predict, you must know the Adabas file number of the
Predict dictionary and the name of the view that you want to map to. If you
are not using Predict, you must know the number of the Adabas file that you
want to map to.
Restrictions
- Each column in the table that you create must be associated with a field
in the file, a superdescriptor, or a subdescriptor.
- If Predict formatting is available, the following Predict formats are
supported:
- character (A,AL,AV)
- binary (B) with length of 2 or 4
- date (D, DS, DT)
- floating point (F)
- integer (I)
- logical (L)
- numeric packed and unpacked (N, NS, P, PS, U, US)
- time (T, TS)
If only Adabas field formatting is available, the following formats are
supported:- alphanumeric (A)
- binary (B) with length of 2 or 4
- fixed point (F)
- floating point (G)
- packed decimal (P) and unpacked decimal (U)
About this task
For
more information about creating tables and views that map to Adabas databases,
see the related links for Adabas syntax diagrams and for views.
Procedure
To create an Adabas table and optionally a
view for change capture:
- Optional: Use the Adabas page of the Preferences window
to set these default values:
- The name of the Predict dictionary that you want to use.
- The date format that Classic Data Architect should convert dates to.
- The time format that Classic Data Architect should convert times to.
- The maximum length for VARCHAR data.
- The maximum length for LVARCHAR data.
- The maximum number of occurrences for all fields that occur multiple times
in an Adabas file.
- Whether to use the User Synonym field from the
Predict Dictionary when this field is defined.
- Map your Adabas database to a relational table by using the New
Adabas Table wizard.
- Open this wizard by right-clicking either the database in your
data design project or one of the schemas within the database. Select Add
Classic Object > Adabas table.
- Select the model and schema in which to create the table.
- Choose whether or not to create a view on the table.
- Choose either to connect to your Adabas database through an
existing connection to a data server, or to create a new connection to a data
server. Either data server must be configured to access the Adabas
database.
- Specify the format of dates and times, the lengths of VARCHAR
and LVARCHAR data types, and the maximum number of occurs. The
default values that appear are either the global defaults that are set for
the Adabas database or the defaults that are set in the Adabas page
of the Preferences window.
- Specify that you want to use the table (and view, if you are
creating one) for change capture.
- Provide either the Predict or Adabas information that is necessary
for the discovery process.
- Select the Adabas fields to map to columns in your relational
table.
- Optional: In the ISN name
field, provide a name for the column that maps to the Adabase Internal Sequence
Number (ISN).
The default column name is ISN.
- If you are creating a view, specify the criteria for the WHERE
clause.
- Modify the names of columns and provide null values.
When you finish the wizard, the new table appears under the selected
schema. If you created a view, the view also appears under the selected schema.
- Optional: Modify the table properties or add privileges.
Select the table and make any changes in the Properties view.
- Optional: Generate the DDL for the table. You
can generate the DDL later, if you do not want to generate it now. You can
also generate the DDL for all of the objects within the same schema. See Generating DDL.
- Right-click the table and select Generate DDL.
- In the Generate DDL wizard, follow these steps:
- Choose to generate CREATE statements.
- Choose to generate DDL for tables.
- Name the file in which to save the DDL within your project.
- Choose whether to run the DDL on a data server. After you run the DDL,
check the Data Output view to determine whether the DDL
ran successfully.
- Choose whether to open the DDL for editing.
- Optional: If you ran the DDL successfully on a data
server, validate the table by running a test query against your Adabas database.
Be sure that the data server is connected to that database.
- In the Database Explorer, search your data server for the schema
that you created the table in. Expand the schema and expand the Tables folder.
- Right-click the table and select Data > Sample
Contents.
- Check the Data Output view to determine
whether the test query ran successfully.
- Optional: If you created a view,, generate the DDL
for the view. You can generate the DDL later. You can also generate
the DDL for all of the objects within the same schema. See Generating DDL.
- Right-click the view and select Generate DDL.
- In the Generate DDL wizard, follow these steps:
- Choose to generate CREATE and ALTER statements.
- Choose to generate DDL for views.
- Name the file in which to save the DDL within your project.
- Choose whether to run the DDL on a data server. After you run the DDL,
check the Data Output view to determine whether the DDL
ran successfully.
- Choose whether you want to open the DDL for editing.
- Optional: If you ran the DDL successfully on a data
server, validate the view by running a test query against your Adabas database.
Be sure that the data server is connected to that database.
- In the Database Explorer, search your data server for the schema
that you created the view in. Expand the schema and expand the Views folder.
- Right-click the view and select Data > Sample
Contents.
- Check the Data Output view to determine whether the test query
ran successfully.