4.1 Defining a Data Source

To connect to other types of databases, see Relational Databases and Non-Relational Data Sources in Data Modeling.

Before you build queries or data models, you must create the datasource that defines the connection to your data. The following example shows you how to define a JDBC (Java Database Connectivity) datasource.

In this walkthrough, you will define a new JDBC data source called 'SampleOrders'. Follow the steps below.

1. Press the 'New' button in the toolbar. This opens the 'New Asset' dialog box.

2. In the left panel of the 'New Asset' dialog box, press the 'Data Source' node on the tree.

3. In the right panel, select 'JDBC', and press 'OK'.

 

This opens the 'JDBC Data Source Wizard'.

4. Enter “SampleOrders” in the name field, and press 'Next'.

 

If you connect to your own JDBC data source, make sure that you add the vendor-specific driver JAR file(s) to the classpath. See Configuring the Style Studio Class­path.

5. Select 'Derby Embedded' from the menu for the 'JDBC Type'. The correct driver, org.apache.derby.jdbc.EmbeddedDriver, automatically appears in the 'JDBC Driver' field.

 

6. Press 'Next' to continue to the 'JDBC URL' page.

Every JDBC driver has a unique connec­tion 'JDBC URL'. You can obtain this from the database vendor.

7. In the 'JDBC URL' field, enter “jdbc:derby:classpath:orders”. This is the connection URL for the sample Derby database.

8. Uncheck the 'Requires Login' option. (Otherwise you will be prompted for a username and password.)

 

9. Press 'Finish' to display the final Data Source definition page.

 

After you save the data source, it will appear in the left-side Asset panel under the 'Data Source' node.

10. Press the 'Save' button in the toolbar to save the new data source.

11. Verify that you can connect to the database. Press the 'Test Data Source' button in the top toolbar. A message will inform you if the connection was successful.

 

<< 4 Getting Started with Data Modeling © 1996-2013 InetSoft Technology Corporation (v11.5) 4.2 Getting Started With Data Models >>