× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi Nick,

I am trying to connect to a SQL server 2000 running on a windows 2003
server.
This is the joblog error that I get:

Please create a test environment for your program with the following attributes:

a) Make sure the Java JVM has NOT yet loaded.

b) Make sure you do NOT have the QIBM_USE_DESCRIPTOR_STDIO environment
variable set. If you're not sure, type:

RMVENVVAR ENVVAR(QIBM_USE_DESCRIPTOR_STDIO)

NOTE: the variable name is case-sensitive. It must be upper case.

c) Type the following two overrides:

OVRPRTF FILE(STDOUT) TOFILE(QSYSPRT) HOLD(*YES) OVRSCOPE(*JOB)
OVRPRTF FILE(STDERR) TOFILE(QSYSPRT) HOLD(*YES) OVRSCOPE(*JOB)

e) Call your RPG program that tries to connect via JDBC. (It must
run in the SAME JOB, don't use SBMJOB unless you put the
RMVENVVAR and OVRPRTFs in that job as well.)

f) After the failure and all of the errors, etc. SIGN OFF.
(Or, if it's a batch job, end the job.) This unloads the JVM
from memory.

g) Sign back on and check your spooled files for any error messages
from Java. See if you can determine the problem from these messages.
If not, post them here.


Note: What the above procedure does is capture the STDOUT and STDERR from the Java program to a spooled file. There are other ways to achieve this, but I find this to be the simplest one.

Note: CallConnectMethod() prototype that you refer to as a "C program" is actually just a renamed prototype for the CallObjectMethod() API. This is an IBM-supplied API that's part of the Java (5722-JV1) licensed program. It's really just a way of calling a Java method -- much like the CALL command is just a way of calling an RPG program. Sure, IBM may have written the code for the CALL command in C, but if the RPG program is giving an error, it's the RPG code you need to debug, not the code that's internal to the CALL command itself! And the same is true here... you don't want to view what's happening in the CallObjectMethod() API -- that's just the CALL command. You want to see what's happening in the SQL server JDBC driver, which is written in JAVA, not C. And I seriously doubt that Microsoft gave you the source code for it, so I don't think you'll be able to create a debugging view.

Hopefully the override stuff I discussed earlier will give you the error message you need.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.