× 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.



Good info. We'll have to see what we can set via the ADO.NET connection string.



-----Original Message-----
From: CRPence [mailto:crpbottle@xxxxxxxxx]
Sent: Thursday, June 11, 2015 1:26 PM
To: midrange-l@xxxxxxxxxxxx
Subject: Re: Stored procedure test environment

On 11-Jun-2015 12:14 -0600, CRPence wrote:
On 08-Jun-2015 10:39 -0600, Justin Taylor wrote:
A test user ID sounds like an easy way to set the proper library
list.

What about choosing the proper stored procedure (SP)? Right now, all
our SP calls include the schema name. I seem to recall I you don't
specify a schema, DB2 tries to use the user ID as the schema.
We don't [want] to have to change the calls between test and
production environments.


Unqualified names on CALL and use either the default path with *SYS
naming or use SET PATH with *SQL naming when the default path of the
authorization Id is undesirable [likely to be undesirable when testing
while using a setup that is established according-to User Profile
name, except in the unlikely case the non-test environment already
operates according to the UsrPrf name].


I failed to add, that specifically, the desirable SET PATH would be:
SET PATH *LIBL

[http://www.ibm.com/support/knowledgecenter/ssw_ibm_i_71/db2/rbafzsetpath.htm]
_SET PATH_
"The SET PATH statement changes the value of the CURRENT PATH special register.
Invocation

This statement can be embedded in an application program or issued interactively. It is an executable statement that can be dynamically prepared.
...
The initial value of the CURRENT PATH special register is *LIBL if system naming was used for the first SQL statement run in the activation group. The initial value is "QSYS","QSYS2","SYSPROC","SYSIBMADM","X"
(where X is the value of the USER special register) if SQL naming was used for the first SQL statement.

Using the SQL path: The CURRENT PATH special register is used to resolve user-defined distinct types, functions, and procedures in dynamic SQL statements. For more information see SQL path.
..."

Hmm, I peeked at the OP, and I noticed the CALL statements could be compiled\embedded vs dynamic. Be sure the static calls use the Library List (*LIBL) as the PATH as well.

--
Regards, Chuck



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.