Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

User-Defined Callbacks on OpenVMS

user1867402May 4 2015 — edited May 5 2015

Hello all,

I've been experimenting recently with User-Defined Callbacks (OCI Programming Advanced Topics) and I'm curious if they are supported on OpenVMS.

I've had no trouble getting the sample programs (cdemoucb.c and cdemoucbl.c) or my own code to work on Linux.  The directions given in the link above for Solaris also work well on Linux.  Basically, you just create the module, name it something like ucbtest.so.1.0 (with the .so.0.1 extension), copy it to $ORACLE_HOME/lib and set the environment variable ORA_OCI_UCBPKG=ucbtest.

Does anyone know if UCB's work on OpenVMS?  If so, what's the trick?

I can create a shareable image.  I can verify that it is possible to load functions from it using LIB$FIND_IMAGE_SYMBOL and run them.  I can set either a symbol or a logical ORA_OCI_UCBPKG=ucbtest.  I'm having trouble getting it to work from an OCI program though.  In my test program, if the logical or symbol is set, then OCIEnvCreate fails with OCI_ERROR, even if OCI_NO_UCB is specified.  If I use OCIInitialize, it also fails with OCI_ERROR.

Poking around in the Oracle libraries, I see the ORA_OCI_UCBPKG string, and since OCIEnvCreate/OCIInitialize fails, it would appear that they are actually trying to do something to load the module.

So, maybe I'm just doing something wrong.

* Should the module be created as a shareable image, or something else?

* Must the image be installed (using the INSTALL utility), or is it ok if it's not?

* How should the module be named?  Files can't have more than 1 dot in their names on OpenVMS.  I've tried the default of .EXE.  I also tried .SO and .DLL, but no luck.

* Where should the module be located?  The default location for shareable images on OpenVMS is SYS$SHARE.  Should it go there, or in ORACLE_HOME:[lib]?  Or somewhere else?  I've tried all combinations of .EXE, .SO, .DLL and both of those locations, but nothing has worked so far.

* Should ORA_OCI_UCBPKG be a logical, a symbol, or something else?

* Are there any other logicals/symbols that need to be set too?

Any help that anyone could give me would be great.

Thanks!

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 1 2015
Added on May 4 2015
0 comments
545 views