Sample Request Program

After you import the OperationsOracle sample project to TIBCO Business Studio, all the preconfigured processes are displayed in the Project Explorer view.

You can use the sample request program to demonstrate features, such as returning the rows in the OPERATION_ORDER table, batching requests, binding time and binary values, and running other SQL commands.

RPC Standard Operation

The ADBServer adapter service and processes [1] to [5] show the RPC standard operation support. This program emulates an RPC client application that sends requests to an adapter configuration for processing.

The following table lists the selections available in the sample request program for the RPC standard operation with the Rendezvous transport:

Selection Description
[1] INSERT INTO OPERATION_ORDER Sends a request to the adapter to insert a record that is used to update the OPERATION_ORDER table. You are prompted to provide the order ID, description, and price. For example:

Enter the order_id: 1

Enter the order_description: 'teal table'

Enter the order_price: 1.99

[2] SELECT FROM OPERATION_ORDER Sends a request to the adapter to return all rows from the OPERATION_ORDER table.
[3] Execute Any SQL Statement (DLL & DML) Constructs a custom request and sends it to the adapter by using an INSERT, UPDATE or DELETE statement.
[4] Execute Batch of SQL Statements Sends a request to the adapter to execute two INSERT statements as a batch operation.
[5] Execute SQL Stmt with Bind Variables Sends an INSERT statement to the adapter to update the OPERATION_ORDER table. You are prompted to provide a SQLstatement "insert into operation_order values (?,’123’,1.22)".

Select BINDS > item and then you have to enter the values in the POSITION field and the DATA field.

Note: The anyType data type is used as the default value in the DATA field. If you use this data type, an error message indicating a wrong message format is displayed when you run the BusinessWorks process. To resolve this issue, you have to substitute this data type with Simple Type. For details on how to change the anyType AE Schema data type, see "Handling the anyType AE Data Type" in TIBCO ActiveMatrix Adapter for Database (TIBCO Business Studio) User’s Guide.

The POSITION field value depends on the number of the question marks (?) in the preceding SQL statement.

If more than one question mark exists in the SQL statement, you have to duplicate the item by right-clicking item > Duplicate.

RPC Custom Operation

The ADBServer1 adapter service and processes [6] to [9] show the RPC custom operation support. This program emulates an RPC client application that sends requests to an adapter configuration for processing.

The following table lists the selections available in the sample request program for the RPC custom operation with the Rendezvous transport:

Selection Description
[6] Execute procedure SetDescription_input Run the SetDescription procedure, which takes an item description as input and writes it to the operation_order table. For example:

Enter the id: 30

Enter the order_description: ’spec material’

[7] Execute procedure getPrice_output Run the getPrice procedure, which returns an item price for the specified id. For example:

Enter the id: 30

Returns the price value for the specified order.

[8] Execute procedure paramTest_multiple Run the paramTest procedure, which takes an item name and sequence number as input and returns the description, timestamp, and sequence number values for that record. For example:

Enter the id: 30

Enter the name: ’abc’

Enter the seqno: 15

[9] Pro_Customer_rvClient_ FINDORDERS Oracle REF data type support that is used as an OUT parameter only in an Oracle stored procedure.

Request-Reply Operation

The ADBServer2 adapter service and process [10] show the Request-Reply operation support. This program emulates a Request-Reply application that sends requests to an adapter configuration for processing.

The following table lists the selection available in the sample request program for the Request-Reply operation with the Rendezvous transport:

Selection Description
[10] Request_Reply SELECT FROM OPERATION_ORDER Sends a request to the adapter to return all rows from the OPERATION_ORDER table.