From a table or view
About this task
When you generate a type tree for a table or view, information from your database and from the Database Interface Designer is used to create a type tree file (MTT). If you change your database table definition or edit the database definition in the Database Interface Designer, you must generate a new type tree to reflect the new information.
Generated type trees may differ when generated using different database adapters. For example, a date field may be represented differently by different databases. For this reason, use the same adapter type that will be used at run time to generate the type tree with the Database Interface Designer. Or, if you use ODBC, use the Column Attributes Override dialog that is described in the Resource Adapters documentation.
To define the type tree to generate from a table or view, use the Generate Type Tree from Tables dialog or the Generate Type Tree from Views dialog. The following table contains fields and descriptions.
Database Name | This is the name of the database from which you want to generate a type tree. (This name is automatically inserted based upon your selection in the Navigator.) |
Tables/Views | This list displays all of the tables, views, or
synonyms that have been defined in this database. Select one or more from
this list. Note: If the table, view, or synonym you
want is not displayed in this list, add it by right-clicking in the list,
selecting Insert, and typing the desired name.
|
File name | This field displays a system-generated file name
based upon the database selection in the Navigator. The default value is the database name with a type tree
extension (MTT) and a default path. To change any of this information, click the browse button. |
Overwrite file | This check box determines whether you want to replace the existing type tree file (MTT) upon saving it. The default value is disabled. |
Override type | This check box determines whether to replace existing types with matching, newly generated types and to add any non-matching new types to the type tree file (MTT). This is useful when you want to add types for additional tables into an existing type tree. The default value is enabled. |
Row group format | This list displays options to determine the row
format in the generated type tree. The default value is
Delimited.
|
Delimiter | This is the value for the delimiter to be used when generating this type tree. For a list of available symbols, click the browse button. The Symbols dialog appears, allowing you to select the desired value. The default value is a pipe character (|). |
Terminator | This is the value for the terminator to be used when generating this type tree. For a list of available symbols, click the browse button. The Symbols dialog appears, allowing you to select the desired value. The default value is <CR><LF >. |
Release | This is the value for the release character to be used when generating this type tree. For a list of available symbols, click the browse button. The Symbols dialog appears, allowing you to select the desired value. The default value is an exclamation point (!). |
Override Column Definitions | (For ODBC only) This check box indicates whether
the database driver (with check box disabled) or a command line override
(with check box enabled) is used to interpret columns. The default value is
disabled. For more information about this field, see the adapter-specific documentation in each adapter reference guide. |
Generate type trees in 1.4.0 format | (For Oracle adapter only) This check box
determines whether you can generate type trees that are compatible with maps
for Version 1.4.0. You might enable this functionality if you have legacy
1.4.0 maps that you want to maintain for some reason. The default value is
disabled. For more information about this field, refer to adapter-specific documentation in each adapter reference guide. |
Represent date/time columns as text items |
If you are generating new type trees, make sure this check box is disabled. The default is disabled. Because of adapter-specific differences in date and time formats, see the adapter-specific instructions in each adapter reference guide. |
Treat text item as | This list displays the languages available in which to handle text items. The default value is Western. |
To generate a type tree from a table or view:
Procedure
Results
The generated type tree is represented in the Navigator with the table/view icon next to the name.