Oracle SQL functions – PB Docs 126

Oracle SQL functions

SQL statements, you can use any function that Oracle supports (such
as aggregate or mathematical functions).

For example, you can use the Oracle function UPPER in a SELECT

Calling OCI functions

While PowerBuilder provides access to a large percentage of
the features within Oracle, in some cases you may want to call one
or more OCI functions directly. In PowerBuilder you can use external
function declarations to access any Windows DLL.

The OCI calls qualify for this type of access. Most OCI calls
require a pointer to an LDA_DEF structure as their first
parameter. If you want to call OCI functions without reconnecting
to the database to get an LDA_DEF pointer, use the PowerScript
DBHandle function.


DBHandle takes a transaction object as a parameter and returns
a long variable, which is the handle to the database for the transaction.
This handle is actually the LDA_DEF pointer that PowerBuilder
uses internally to communicate with the database. You can use the
returned value in your DLLs and pass it as one of the parameters
in your function.


This example shows how to use DBHandle. Assume a successful
connection has occurred using the default transaction object (SQLCA):

In your DLL, cast the incoming long value into a pointer to

Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Notify of
Inline Feedbacks
View all comments
Would love your thoughts, please comment.x