DB Import is a TIBCO Designer-based utility that allows you to connect to a database and import schemas. This utility enables you to select tables or views to import and creates corresponding BusinessEvents database concepts. By default the utility names the database concepts using the table or view name. You can, however, provide different names as desired.The utility provides an option to create one event for each table or view. The generated event’s payload corresponds to the schema of the concept created for that table or view. These events can then be used to perform operations such as queryUsingPrimaryKeys().The first step is to set up a JDBC Connection resource in the project and configure it for the database whose tables or views you want to import.Instructions are provided in a different section of this guide. See Adding a JDBC Connection Resource, and adapt the instructions as needed. Remember to include the JDBC Connection resource as a shared resource (as explained in that section).
You can import concepts into the project from multiple data sources using different JDBC connections.
1. From the TIBCO Designer window menu bar, go to Tools > BusinessEvents Tools > DB Import. The DB Import wizard displays, showing the Specify Database Connection dialog:
2. In the JDBC Resource URI field, Click the Browse button and select a JDBC Resource URI. The database connection details display. Override the connection details if needed, then click Next. You see the Project Resource Location dialog.
3. In the Concept Folder field, browse to and select or create the project folder for the database concepts.
4. (Optional) Check the Generate Events checkbox if you want to create a simple event for each imported concept. When you check the Generate Events checkbox, additional fields appear for you to specify details for the events.
b. In the Event Destination URI field, click the Browse button and select the default destination for the events.
5. Click Next. You see the Select Database Entities dialog.
6. Select the database entities (tables or views) from which you want to create database concepts (and events if you selected that option).
7. (Optional) Select the Generate Concept Relationships checkbox if you want to create relationships between concepts (concept reference or contained concept) based on database constraints.The utility imports any additional database entities that were not in the original selection but that must be imported because they have a relationship to the selected subset of entities. If this is the case, a message such as the following displays:
8. At the Concept Name For Database Entity dialog, database schema names are provided as default names of the BusinessEvents concepts. Edit the BusinessEvents concept names as desired, then click Finish.
9. The utility creates the concepts (and events if you chose that option). Browse your project tree to verify that the expected concepts and events have been created.
Copyright © TIBCO Software Inc. All Rights Reserved.