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


Chapter 5 Editing a Table Definition : Copying a Definition

Copying a Definition
There are a number of methods that you can use to copy an existing table definition. Using an existing definition and modifying only the portions required simplifies coding and the assignment of data. In the case of distributed development, it also assists in the management of table definitions across nodes as the table containing the data must be defined on the local and remote nodes.
You can copy a definition from within the Table Definer or through the use of shareable tools. If the source table is on a TIBCO Object Service Broker node that is remote to the one you are working on, you must copy the definition using a shareable tool.
Copying a Definition Using the Table Definer
When you are within an existing definition in the Table Definer, you can copy a definition by doing one of the following:
Using the COPY command.
To use this command, at the primary command field type COPY tablename where tablename is the name of the table that you are copying.
When using the COPY command:
The name of the table that you are viewing is retained but all the other information in the definition is overwritten with the values from the copied table.
Copying a Definition Using Shareable Tools
Two shareable tools, COPY_DEFN and COPYDEFN, are available to you to copy existing definitions. Using these tools, if the correct security access is set up, you can copy definitions across TIBCO Object Service Broker nodes or within your local node. COPY_DEFN is called from within a rule and COPYDEFN executed via the workbench option CD copy defn.
Example Rule
The following rule calls the tool COPY_DEFN to copy the definition of the DEPARTMENTS table from Node A to Node B. Because a table definition is being copied, values are not required for the arguments library, environment, or parentonly:

 
COPY_TABLEDEFN;
_
_ ---------------------------------------------------------------------------
_ ------------------------------------------------------------+--------------
_ CALL COPY_DEFN(’TABLE’, ’DEPARTMENTS’, ’’, ’’ , ’NODEA’, | 1
_ ’NODEB’, ’’); |
_---------------------------------------------------------------------------

 
See Also
TIBCO Object Service Broker Shareable Tools for information on the tools.

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