Originally posted by: paul.brett
I had a situation recently, where the client had a requirement that the same compiled map be used across multiple z/OS environments, where each environment had different database connection parameters.
One solution to this would be of course, the Resource Registry.
However, as there was no requirement for the MDQ to remain the same across the environments, I instead proposed the following (more simple) solution:
The map was compiled with input card parameters such as:
-MDQ MDQFILE -DBNAME PRIMARY -QUERY QUERY_EMPLOYEE_DATA
...and the output card parameters such as:
-MDQ MDQFILE -DBNAME PRIMARY -TABLE USER.EMPLOYEES
The entry 'PRIMARY' above, refers to the simple text label given to each database access entry in the MDQ file, and is simply a pointer to that entry. The entry itself contains the database access parameters:
<DATABASE name="PRIMARY">
<TYPE>DB2</TYPE>
<PLATFORM>MVS</PLATFORM>
<QUALIFIEDNAMES>true</QUALIFIEDNAMES>
<SURROUNDCHARS></SURROUNDCHARS>
<PLAN>DBUTILE</PLAN>
<SUBSYSTEM>DI07</SUBSYSTEM>
<DESIGNSOURCE>MainframeDB2V10</DESIGNSOURCE>
<USER>PAB1</USER>
<PASSWORD.encrypted>#I37BQz&0z</PASSWORD.encrypted>
</DATABASE>
....and the MDQ parameters for PLAN and SUBSYSTEM can be different in each file, in each environment.
It must be noted that as per documentation here:
http://www-01.ibm.com/support/knowledgecenter/SSVSD8_8.4.1/com.ibm.websphere.dtx.adapdbzos.doc/concepts/c_db2_zos_Database_Interface_Designer_Settings.htm
...the USER and PASSWORD fields are only used in the Database Interface Designer context, and are completely ignored at runtime. The credentials of the user running the map is used to authenticate to the database.
Thank-you.
Paul
Follow me on Twitter
#IBM-Websphere-Transformation-Extender#IBMSterlingTransformationExtender#DataExchange