Importing Domain Model Entries from a Database Table

When you import domain model information from a database, the result set from the SQL query is transformed for use as domain model entries. This feature is supported with Oracle Database.

If imported from a database concept, database table, or a database query, you can update the domain model by using the Reload Domain Model button available on the top bar of the Domain Model editor.

Procedure

  1. Add a JDBC Connection resource and configure it to connect to the database from which you want to import the domain model. See JDBC Connection Reference for details.
  2. In BusinessEvents Studio Explorer, do one of the following:
    • Right-click the folder where you want to create the domain model and select Import > TIBCO BusinessEvents > Domain Model.
    • In BusinessEvents Studio Explorer, select any item in the project entity and select File > Import > TIBCO BusinessEvents > Domain Model.
  3. Click Next. You see the Import Domain Model Wizard.

    If you invoked the import wizard by right-clicking a folder, that folder is selected as the parent folder. You can choose a different one as desired.

  4. In the Domain Import Source field, select DATABASE_TABLE.
  5. In the File Name field, enter a name for the domain model resource. Optionally enter a description.
  6. In the Data Type field, select the appropriate data type for the domain model and click Next. You see the next wizard page.
  7. In the JDBC Resource URI field, browse and select the JDBC Connection resource that connects to the database you want to use.

    The connection information from the JDBC Connection resource displays. You can override it here as desired.

    Click Next. You see a list of tables in the database. Expand the list of tables to see the columns that match the datatype specified in step 6.

  8. Do one of the following:
    • Select one or more columns, then click the Create Domain for Selected Columns button. Values of all columns are used for the domain model entries.
    • Click Advanced and enter an SQL query whose resultset is used to create the domain entries. This option enables you to make use of joins, where clauses, and so on. Then click Execute Query.
  9. Click Finish. You see a message, "Domain Import Successful." Click OK.
  10. You see the Domain Model editor. The column values appear as domain entries. You can add, edit, duplicate, and remove entries as appropriate.