Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 30 JDBC Backing Store Setup : Check the Aliases File, Run the Project Schema Script

Check the Aliases File, Run the Project Schema Script
For every entity, property, or state machine whose database identifier name exceeds the database maximum length, a table name entry is created in the generated yourname.aliases file (for example, acme.aliases). See Ontology Identifiers that Exceed the DBMS Maximum Column Length for more information, and for an alternative way to specify short table names.
It’s a good idea to check the aliases file for entries, even if the TIBCO BusinessEvents names are not very long. The length of the generated database table names is not easy to predict.
Optionally, you can edit the file to provide more meaningful names.
Key word mapping file
Entries in the key word mapping file are also added to the aliases file so you can replace the key word aliases with project-specific ones, as desired (generally in a second pass). For details see Task K, If Needed — Map Key (Reserved) Words to Aliases.
Task I Check the Aliases File and Modify Aliases as Desired
1.
Open the yourname.aliases file for editing.
2.
3.
Re-run the be-jdbcdeploy tool, using the same parameters as before. (For details see Task H, Generate the Project-Schema-Specific SQL Scripts (with Wizard).) This time, the aliases you created are used.
Task J Run the Project Schema Script (as BE_USER)
In this step, you log on as the user you created and run a script to create the project related part of the database schema.
1.
Open a command window in BE_HOME/bin and run the yourname.sql script. (for example, @acme.sql). Use the user BE_USER, password BE_USER (or whatever username and password you set in the script in Task F).
For Oracle:
   sqlplus BE_USER/BE_USER @yourname.sql
For SQL Server:
osql -S Your-Server –d Your-DB -U BE_USER -P BE_USER -n -i @yourname.sql
If there are no errors, your database tables are now configured for use. If there are errors you may need to add some mappings to the key word mapping file.
Task K If Needed — Map Key (Reserved) Words to Aliases
Complete this task only if you saw errors after completing Task J, Run the Project Schema Script (as BE_USER). Such errors are caused when your project ontology uses terms that are key words (reserved terms) in the DBMS you are using. You must map these terms to an alias in the keyword mapping file.
1.
Edit the BE_HOME/dbkeywordmap.xml file to add entries. Below is the format followed by an example:
   <keyword name=“dbKeyWord" mapname=“nonDbKeyWord"/>
   <keyword name="start" mapname="start_"/>
2.
*0
Providing Project-Specific Key Word Aliases  When you repeat Task H, the new key words are added to the yourname.aliases file. You can create project-specific aliases for the key word mappings as desired. Then repeat Task H again and continue.
Next Step (As Needed)
Complete the TIBCO BusinessEvents Studio project configuration tasks if you have not already done so. These tasks can be done before or after database setup. See the following sections:
 

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved