Re: SQLCODE=-904 during RUN

2016-11-04 Thread Janet Graff
>Dropping any table required by a package will invalidate that package. And 
>creating a new table, even if it has the same name, will not right your 
>>package, because that new table is a _different_ object.

>Why not simply TRUNCATE your tables if you want to empty them out before your 
>test run?

>Cheers,

>Jantje.

Jan!

Thanks!  Replacement the DROP/CREATE with the TRUNCATE statement has allowed 
the process to complete succesfully!

Thank you so much!
Janet

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-04 Thread Janet Graff
>HI Janet,
>I noticed that the bind is binding DALLASA.DB2ZP.ZPDB2
>but the error is for DB2ZP.ZPDB2.1A320A2A009C519E.

>It looks like a mis-match between local and remote versions of the package.

>Regards,
> Ron

I've been looking for a way to have both the BIND and the RUN statements agree 
on the location of the package.

The BIND statement has this syntax

BIND PACKAGE__(_ ___ _.collection-id)__ _ 
_> |
   | |_location-name_|  
|_OWNER(authorization-id)_|   |

where I could specify a location-name on the collection id.  But DALLASA is the 
correct location so I don't need to change the BIND statement.


The RUN STATEMENT doesn't even specify a collection-id and has no syntax to 
specify the location

 | >>__RUN__ _PROGRAM(program-name)__ _ _ __> |
   |  ||_PLAN(plan-name)_| ||
   |  |_CP__PLAN(plan-name)||
   ||
   | >__ ___ __ _ ___>< |
   ||_LIBRARY(library-name)_|  |_PARMS(parameter-string)_|  |

So how do I get the RUN statement to use the right package?

Janet

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-04 Thread Jantje.
O, and BTW, there is an excellent body of knowledge and knowledgeable people at 
http://www.idug.org/p/fo/si/topic=19

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-04 Thread Jantje.
On Wed, 2 Nov 2016 13:39:48 -0500, Janet Graff  wrote:


>Yes this is part of my test automation so to make sure the result sets are 
>clean I am dropping and recreating the tables every time through.
>
>Are you saying I need to sequence this?  So the Drop/Create is done and THEN 
>then BIND?
>

Yes.

Dropping any table required by a package will invalidate that package. And 
creating a new table, even if it has the same name, will not right your 
package, because that new table is a _different_ object.

Why not simply TRUNCATE your tables if you want to empty them out before your 
test run?

Cheers,

Jantje.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-02 Thread Janet Graff
>I am not getting the DROP/CREATE table part here... Are these the tables that 
>are used in your program? Because if they are, then dropping them >will 
>invalidate all packages accessing them. And re-creating the tables will *not* 
>rebind your packages. After all, even if they have the same name, >your tables 
>will be different, new objects. And any program that uses the invalidated 
>packages will fail...

>Cheers,

>Jantje.

Jan,

Yes this is part of my test automation so to make sure the result sets are 
clean I am dropping and recreating the tables every time through.

Are you saying I need to sequence this?  So the Drop/Create is done and THEN 
then BIND?

Janet

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-02 Thread Janet Graff
>HI Janet,
 >I noticed that the bind is binding DALLASA.DB2ZP.ZPDB2
>but the error is for DB2ZP.ZPDB2.1A320A2A009C519E.
>
>It looks like a mis-match between local and remote versions of the package.
>
>Regards,
 > Ron

Ron,

What step do I fix that on and what keyword do I specify?

Thanks!
Janet

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-02 Thread Jantje.
On Tue, 1 Nov 2016 16:07:59 -0500, Janet Graff  wrote:

> DSN SYSTEM(DBAG)  
>  
>DSN
> 
> BIND PACKAGE(DB2ZP) MEMBER(ZPDB2) ACT(REP) ISO(CS) CURRENTDATA(YES) 
> ENCODING(EBCDIC)

>DSN
> 
> BIND PLAN(DB2ZP) PKLIST(DB2ZP.*) ACT(REP) ISO(CS) CURRENTDATA(YES) 
> ENCODING(EBCDIC)

I don't think you need to bind your plan over and over. The way you specify the 
package list, new versions of the package will be picked up. But that is not 
the problem...


>DSN
> 
> RUN  PROGRAM(DSNTIAD) PLAN(DSNTIA10)LIB('DSNA10.DBAG.RUNLIB.LOAD')
>  
>DSN
> 
> END   
>  
>READY  
> 
>END
> 
> DSNTIAD  - SAMPLE DYNAMIC SQL PROGRAM 2.0
>  
>   DROP TABLE JIG.TESTDB2 
>DSNT400I SQLCODE = 000,  SUCCESSFUL EXECUTION 
>  
>   CREATE TABLE JIG.TESTDB2   
> (MYAUTO  CHAR(16) FIELDPROC VSHFPX01 ('CRYPTID=@WAGA@MYAUTO'),   
>  MYCCN   CHAR(16) FIELDPROC VSHFPX01 ('CRYPTID=@WAGA@MYCCN'),
>  MYSSN   CHAR(11) FIELDPROC VSHFPX01 ('CRYPTID=@WAGA@MYSSN'),
>  MYSST   CHAR(16) FIELDPROC VSHFPX01 ('CRYPTID=@WAGA@MYSST'))
>   IN VOLTTEST.VOLTTAB
>DSNT400I SQLCODE = 000,  SUCCESSFUL EXECUTION 
>  
>   DROP TABLE JIG.TESTDB22
>DSNT400I SQLCODE = 000,  SUCCESSFUL EXECUTION 
>  
>   CREATE TABLE JIG.TESTDB22  
> (MYAUTO  CHAR(16),   
>  MYCCN   CHAR(16),   
>  MYSSN   CHAR(11),   
>  MYSST   CHAR(16))   
>   IN VOLTTEST.VOLTTAB
>DSNT400I SQLCODE = 000,  SUCCESSFUL EXECUTION 
>

I am not getting the DROP/CREATE table part here... Are these the tables that 
are used in your program? Because if they are, then dropping them will 
invalidate all packages accessing them. And re-creating the tables will *not* 
rebind your packages. After all, even if they have the same name, your tables 
will be different, new objects. And any program that uses the invalidated 
packages will fail...

Cheers,

Jantje.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-02 Thread Jantje.
On Mon, 31 Oct 2016 14:01:56 -0500, Janet Graff  wrote:

>Truncations on the right side of the JES output, let me know if you need that 
>data
>
>
>   J E S 2  J O B  L O G  --  S Y S T E M  S 0 W 1  --  N O D 
> E 

I am afraid I'll need to see all sysout as well...

Cheers,

Jantje.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


Re: SQLCODE=-904 during RUN

2016-11-01 Thread Ron hesketh
HI Janet,
 I noticed that the bind is binding DALLASA.DB2ZP.ZPDB2
but the error is for DB2ZP.ZPDB2.1A320A2A009C519E.

It looks like a mis-match between local and remote versions of the package.

Regards,
  Ron



From:   Janet Graff <004dc9e91b6d-dmarc-requ...@listserv.ua.edu>
To: IBM-MAIN@LISTSERV.UA.EDU,
Date:   02/11/2016 05:08 AM
Subject:    Re: SQLCODE=-904 during RUN
Sent by:IBM Mainframe Discussion List <IBM-MAIN@LISTSERV.UA.EDU>



>On Fri, 28 Oct 2016 18:12:01 -0500, Janet Graff <janet.gr...@yahoo.com>
wrote:

>>I have the program pre-compile, compile, pre-linking, linking and binding
all with return code zeros.
>Can we see the JCL, or better still, the entire job log?

...

>Jantje.

Here's the output from the bind
Again JES data truncated on the right

13.57.58 JOB03253  MONDAY,31 OCT 2016 

13.57.58 JOB03253  IRR010I  USERID JIG  IS ASSIGNED TO THIS JOB.

13.57.59 JOB03253  ICH70001I JIG  LAST ACCESS AT 13:57:42 ON MONDAY,
OCTOBER
13.57.59 JOB03253  $HASP373 JIGDB2   STARTED - INIT 2- CLASS A - SYS
S0W1
13.58.00 JOB03253  -  -TIMINGS
(MINS.)--
13.58.00 JOB03253  -STEPNAME PROCSTEPRC   EXCP   CONN   TCB
SRB  C
13.58.00 JOB03253  -RUN  00212
30   .00   .00
13.58.00 JOB03253  -JIGDB2   ENDED.  NAME- TOTAL TCB
CPU TIM
13.58.00 JOB03253  $HASP395 JIGDB2   ENDED

-- JES2 JOB STATISTICS --

  31 OCT 2016 JOB EXECUTION DATE

   39 CARDS READ

  174 SYSOUT PRINT RECORDS

0 SYSOUT PUNCH RECORDS

7 SYSOUT SPOOL KBYTES

 0.01 MINUTES EXECUTION TIME

1 //JIGDB2 JOB MSGCLASS=H,MSGLEVEL=(1,1),NOTIFY=

  IEFC653I SUBSTITUTION JCL - MSGCLASS=H,MSGLEVEL=(1,1),NOTIFY=JIG

2 //RUN  EXEC PGM=IKJEFT01,DYNAMNBR=20,COND=(4,LT)

3 //STEPLIB   DD  DISP=SHR,DSN=DSNA10.DBAG.RUNLIB.LOAD

4 //SYSLIBDD  DISP=SHR,DSN=JIG.BASE710.LOAD

5 //  DD  DISP=SHR,DSN=DSNA10.DBAG.RUNLIB.LOAD

6 //DBRMLIB   DD  DISP=SHR,DSN=JIG.DBAG.DBRMLIB.DATA

7 //SYSTSPRT  DD  SYSOUT=*

8 //SYSPRINT  DD  SYSOUT=*

9 //CEEDUMP   DD  SYSOUT=*

  //*SYSUDUMP  DD  SYSOUT=*

   10 //ZPIDWAGA  DD  SYSOUT=*

   11 //SYSOUTDD  SYSOUT=*

   12 //REPORTDD  SYSOUT=*

   13 //SYSIN DD  *

  //*

   14 //SYSTSIN   DD  *

  //*

ICH70001I JIG  LAST ACCESS AT 13:57:42 ON MONDAY, OCTOBER 31, 2016

IEF236I ALLOC. FOR JIGDB2 RUN

IEF237I 18C7 ALLOCATED TO STEPLIB

IEF237I 0D39 ALLOCATED TO SYSLIB

IEF237I 18C7 ALLOCATED TO

IEF237I 0D37 ALLOCATED TO DBRMLIB

IEF237I JES2 ALLOCATED TO SYSTSPRT

IEF237I JES2 ALLOCATED TO SYSPRINT

IEF237I JES2 ALLOCATED TO CEEDUMP

IEF237I JES2 ALLOCATED TO ZPIDWAGA

IEF237I JES2 ALLOCATED TO SYSOUT

IEF237I JES2 ALLOCATED TO REPORT

IEF237I JES2 ALLOCATED TO SYSIN

IEF237I JES2 ALLOCATED TO SYSTSIN

IEF237I 18C7 ALLOCATED TO SYS1

IEF285I   DSNA10.DBAG.RUNLIB.LOAD  KEPT

IEF285I   VOL SER NOS= VPDA1D.

IEF142I JIGDB2 RUN - STEP WAS EXECUTED - COND CODE 

IEF285I   DSNA10.DBAG.RUNLIB.LOAD  KEPT

IEF285I   VOL SER NOS= VPDA1D.

IEF285I   JIG.BASE710.LOAD KEPT

IEF285I   VOL SER NOS= VPWRKJ.

IEF285I   DSNA10.DBAG.RUNLIB.LOAD  KEPT

IEF285I   VOL SER NOS= VPDA1D.

IEF285I   JIG.JIGDB2.JOB03253.D103.?   SYSOUT

IEF285I   JIG.JIGDB2.JOB03253.D104.?   SYSOUT

IEF285I   JIG.JIGDB2.JOB03253.D105.?   SYSOUT

IEF285I   JIG.JIGDB2.JOB03253.D106.?   SYSOUT

IEF285I   JIG.JIGDB2.JOB03253.D107.?   SYSOUT

IEF285I   JIG.JIGDB2.JOB03253.D108.?   SYSOUT

IEF285I   JIG.JIGDB2.JOB03253.D101.?   SYSIN

IEF285I   JIG.JIGDB2.JOB03253.D102.?   SYSIN

IEF285I   JIG.DBAG.DBRMLIB.DATAKEPT

IEF285I   VOL SER NOS= VPWRKH.

IEF373I STEP/RUN /START 2016305.1357

IEF032I STEP/RUN /STOP  2016305.1358

CPU: 0 HR  00 MIN  00.03 SECSRB: 0 HR  00 MIN  00.00
SEC
VIRT:   432K  SYS:   368K  EXT: 4408K  SYS:12744K

IEF375I  JOB/JIGDB2  /START 2016305.1357

IEF033I  JOB/JIGDB2  /STOP  2016305.1358

CPU: 0 HR  00 MIN  00.03 SECSRB: 0 HR  00 MIN  00.00
SEC
READY

 DSN SYSTEM(DBAG)

DSN

 BIND PACKAGE(DB2ZP) MEMBER(ZPDB2) ACT(REP) ISO(CS) CURRENTDATA(YES)
ENCODING(EBCDIC)
DSNT254I  -DBAG DSNTBCM2 BIND OPTIONS FOR

   PACKAGE = DALLASA.DB2ZP.ZPDB2.()

   ACTIONREPLACE

   OWNER JIG

   QUALIFIER JIG

   VALIDATE  RUN

   EXPLAIN   NO

   ISOLATION CS

   RELEASE

   COPY

   APREUSE

   APCOMPARE

   APRETAINDUP

   QUERYACCELERATION

  

Re: SQLCODE=-904 during RUN

2016-11-01 Thread Janet Graff
>On Fri, 28 Oct 2016 18:12:01 -0500, Janet Graff  wrote:

>>I have the program pre-compile, compile, pre-linking, linking and binding all 
>>with return code zeros.
>Can we see the JCL, or better still, the entire job log?

...

>Jantje.

Here's the output from the bind
Again JES data truncated on the right

13.57.58 JOB03253  MONDAY,31 OCT 2016   
13.57.58 JOB03253  IRR010I  USERID JIG  IS ASSIGNED TO THIS JOB.
13.57.59 JOB03253  ICH70001I JIG  LAST ACCESS AT 13:57:42 ON MONDAY, OCTOBER
13.57.59 JOB03253  $HASP373 JIGDB2   STARTED - INIT 2- CLASS A - SYS S0W1   
13.58.00 JOB03253  -  -TIMINGS (MINS.)--
13.58.00 JOB03253  -STEPNAME PROCSTEPRC   EXCP   CONN   TCB   SRB  C
13.58.00 JOB03253  -RUN  00212 30   .00   .00   
13.58.00 JOB03253  -JIGDB2   ENDED.  NAME- TOTAL TCB CPU TIM
13.58.00 JOB03253  $HASP395 JIGDB2   ENDED  
-- JES2 JOB STATISTICS --   
  31 OCT 2016 JOB EXECUTION DATE
   39 CARDS READ
  174 SYSOUT PRINT RECORDS  
0 SYSOUT PUNCH RECORDS  
7 SYSOUT SPOOL KBYTES   
 0.01 MINUTES EXECUTION TIME
1 //JIGDB2 JOB MSGCLASS=H,MSGLEVEL=(1,1),NOTIFY= 
  IEFC653I SUBSTITUTION JCL - MSGCLASS=H,MSGLEVEL=(1,1),NOTIFY=JIG  
2 //RUN  EXEC PGM=IKJEFT01,DYNAMNBR=20,COND=(4,LT)  
3 //STEPLIB   DD  DISP=SHR,DSN=DSNA10.DBAG.RUNLIB.LOAD  
4 //SYSLIBDD  DISP=SHR,DSN=JIG.BASE710.LOAD 
5 //  DD  DISP=SHR,DSN=DSNA10.DBAG.RUNLIB.LOAD  
6 //DBRMLIB   DD  DISP=SHR,DSN=JIG.DBAG.DBRMLIB.DATA
7 //SYSTSPRT  DD  SYSOUT=*  
8 //SYSPRINT  DD  SYSOUT=*  
9 //CEEDUMP   DD  SYSOUT=*  
  //*SYSUDUMP  DD  SYSOUT=* 
   10 //ZPIDWAGA  DD  SYSOUT=*  
   11 //SYSOUTDD  SYSOUT=*  
   12 //REPORTDD  SYSOUT=*  
   13 //SYSIN DD  * 
  //*   
   14 //SYSTSIN   DD  * 
  //*   
ICH70001I JIG  LAST ACCESS AT 13:57:42 ON MONDAY, OCTOBER 31, 2016  
IEF236I ALLOC. FOR JIGDB2 RUN
IEF237I 18C7 ALLOCATED TO STEPLIB
IEF237I 0D39 ALLOCATED TO SYSLIB 
IEF237I 18C7 ALLOCATED TO
IEF237I 0D37 ALLOCATED TO DBRMLIB
IEF237I JES2 ALLOCATED TO SYSTSPRT   
IEF237I JES2 ALLOCATED TO SYSPRINT   
IEF237I JES2 ALLOCATED TO CEEDUMP
IEF237I JES2 ALLOCATED TO ZPIDWAGA   
IEF237I JES2 ALLOCATED TO SYSOUT 
IEF237I JES2 ALLOCATED TO REPORT 
IEF237I JES2 ALLOCATED TO SYSIN  
IEF237I JES2 ALLOCATED TO SYSTSIN
IEF237I 18C7 ALLOCATED TO SYS1   
IEF285I   DSNA10.DBAG.RUNLIB.LOAD  KEPT  
IEF285I   VOL SER NOS= VPDA1D.   
IEF142I JIGDB2 RUN - STEP WAS EXECUTED - COND CODE   
IEF285I   DSNA10.DBAG.RUNLIB.LOAD  KEPT  
IEF285I   VOL SER NOS= VPDA1D.   
IEF285I   JIG.BASE710.LOAD KEPT  
IEF285I   VOL SER NOS= VPWRKJ.   
IEF285I   DSNA10.DBAG.RUNLIB.LOAD  KEPT  
IEF285I   VOL SER NOS= VPDA1D.   
IEF285I   JIG.JIGDB2.JOB03253.D103.?

Re: SQLCODE=-904 during RUN

2016-10-31 Thread Janet Graff
>On Fri, 28 Oct 2016 18:12:01 -0500, Janet Graff  wrote:

>>I have the program pre-compile, compile, pre-linking, linking and binding all 
>>with return code zeros.
>Can we see the JCL, or better still, the entire job log?

>>
>>But when I try to RUN I get a -904 indicating that the resource is 
>>unavailable because the package is in a non-executable state.  Since the BIND 
>>>output all says it completed successfully I must be misspecifying something.
>>
>Same thing: can we see the complete run?

>Cheers,

>Jantje.

Truncations on the right side of the JES output, let me know if you need that 
data


   J E S 2  J O B  L O G  --  S Y S T E M  S 0 W 1  --  N O D E 

14.00.14 JOB03255  MONDAY,31 OCT 2016   
14.00.14 JOB03255  IRR010I  USERID JIG  IS ASSIGNED TO THIS JOB.
14.00.14 JOB03255  ICH70001I JIG  LAST ACCESS AT 13:59:56 ON MONDAY, OCTOBER
14.00.14 JOB03255  $HASP373 JIGDB2R  STARTED - INIT 2- CLASS A - SYS S0W1   
14.00.16 JOB03255  -  -TIMINGS (MINS.)--
14.00.16 JOB03255  -STEPNAME PROCSTEPRC   EXCP   CONN   TCB   SRB  C
14.00.16 JOB03255  -RUN  00   2757528   .00   .00   
14.00.16 JOB03255  -JIGDB2R  ENDED.  NAME- TOTAL TCB CPU TIM
14.00.16 JOB03255  $HASP395 JIGDB2R  ENDED  
-- JES2 JOB STATISTICS --   
  31 OCT 2016 JOB EXECUTION DATE
   31 CARDS READ
  107 SYSOUT PRINT RECORDS  
0 SYSOUT PUNCH RECORDS  
7 SYSOUT SPOOL KBYTES   
 0.02 MINUTES EXECUTION TIME
1 //JIGDB2R JOB MSGCLASS=H,MSGLEVEL=(1,1),NOTIFY=,REGION=0M  
  //*   
  IEFC653I SUBSTITUTION JCL - MSGCLASS=H,MSGLEVEL=(1,1),NOTIFY=JIG,REGIO
2 //JOBLIB  DD  DSN=DSNA10.SDSNLOAD,DISP=SHR
3 //DD  DSN=CEE.SCEERUN,DISP=SHR
  //*   
  //* GRANT AND CREATE TABLE
  //* SEPARATE FROM EXECUTION OF PROGRAM
  //*   
  //*   
4 //RUN  EXEC PGM=IKJEFT01,DYNAMNBR=20,COND=(4,LT)  
  //*SYSLIBDD  DISP=SHR,DSN=JIG.BASE710.LOAD
  //* DD  DISP=SHR,DSN=DSNA10.DBAG.RUNLIB.LOAD  
5 //SYSLIBDD  DISP=SHR,DSN=DSNA10.DBAG.RUNLIB.LOAD  
6 //DBRMLIB   DD  DISP=SHR,DSN=JIG.DBAG.DBRMLIB.DATA
  //*DBRMLIB   DD  DISP=SHR,DSN=DSNA10.DBAG.DBRMLIB.DATA
7 //SYSTSPRT  DD  SYSOUT=*  
8 //SYSPRINT  DD  SYSOUT=*  
9 //CEEDUMP   DD  SYSOUT=*  
J E S 2  J O B  L O G  --  S Y S T E M  S 0 W 1  --  N O D 
E 

14.00.14 JOB03255  MONDAY,31 OCT 2016   
14.00.14 JOB03255  IRR010I  USERID JIG  IS ASSIGNED TO THIS JOB.
14.00.14 JOB03255  ICH70001I JIG  LAST ACCESS AT 13:59:56 ON MONDAY, OCTOBER
14.00.14 JOB03255  $HASP373 JIGDB2R  STARTED - INIT 2- CLASS A - SYS S0W1   
14.00.16 JOB03255  -  -TIMINGS (MINS.)--
14.00.16 JOB03255  -STEPNAME PROCSTEPRC   EXCP   CONN   TCB   SRB  C
14.00.16 JOB03255  -RUN  00   2757528   .00   .00   
14.00.16 JOB03255  -JIGDB2R  ENDED.  NAME- TOTAL TCB CPU TIM
14.00.16 JOB03255  $HASP395 JIGDB2R  ENDED  
-- JES2 JOB STATISTICS --   
  31 OCT 2016 JOB EXECUTION DATE
   31 CARDS READ
  107 SYSOUT PRINT RECORDS  
0 SYSOUT PUNCH RECORDS  
7 SYSOUT SPOOL KBYTES   
 0.02 

Re: SQLCODE=-904 during RUN

2016-10-31 Thread Jantje.
On Fri, 28 Oct 2016 18:12:01 -0500, Janet Graff  wrote:

>I have the program pre-compile, compile, pre-linking, linking and binding all 
>with return code zeros.
Can we see the JCL, or better still, the entire job log?

>
>But when I try to RUN I get a -904 indicating that the resource is unavailable 
>because the package is in a non-executable state.  Since the BIND output all 
>says it completed successfully I must be misspecifying something.
>
Same thing: can we see the complete run?

Cheers,

Jantje.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN


SQLCODE=-904 during RUN

2016-10-28 Thread Janet Graff
I have written a simple DB2 program that I'd like to run from Batch.  I'm on 
IBM's Dallas service so I have a limited access to certain datasets.
I have the program pre-compile, compile, pre-linking, linking and binding all 
with return code zeros.

But when I try to RUN I get a -904 indicating that the resource is unavailable 
because the package is in a non-executable state.  Since the BIND output all 
says it completed successfully I must be misspecifying something.

Here's the error

SQLCODE=446704536 -904  
 DSNT408I SQLCODE = -904, ERROR:  UNSUCCESSFUL EXECUTION CAUSED BY AN 
UNAVAILABLE RESOURCE. REASON 00E30305, TYPE OF
  RESOURCE 0801, AND RESOURCE NAME DB2ZP.ZPDB2.1A320A2A009C519E 
 DSNT418I SQLSTATE   = 57011 SQLSTATE RETURN CODE   
 DSNT415I SQLERRP= DSNXEAAL SQL PROCEDURE DETECTING ERROR   
 DSNT416I SQLERRD= -160  0  0  -1  0  0 SQL DIAGNOSTIC INFORMATION  
 DSNT416I SQLERRD= X'FF60'  X''  X''  X''  
X''  X'' SQL DIAGNOSTIC
  INFORMATION

These are the run statements

 DSN SYSTEM(DBAG)   
 RUN  PROGRAM(ZPDB2) PLAN(DB2ZP) -  
  LIB('JIG.BASE710.LOAD')   
 END   

Here's the bind output

READY   
 DSN SYSTEM(DBAG)   
DSN 
 BIND PACKAGE(DB2ZP) MEMBER(ZPDB2) ACT(REP) ISO(CS) CURRENTDATA(YES) 
ENCODING(EBCDIC)  
 DSNT254I  -DBAG DSNTBCM2 BIND OPTIONS FOR   
PACKAGE = DALLASA.DB2ZP.ZPDB2.() 
ACTIONREPLACE
OWNER JIG
QUALIFIER JIG
VALIDATE  RUN
EXPLAIN   NO 
ISOLATION CS 
RELEASE  
COPY 
APREUSE  
APCOMPARE
APRETAINDUP  
QUERYACCELERATION
GETACCELARCHIVE  
 DSNT255I  -DBAG DSNTBCM2 BIND OPTIONS FOR   
PACKAGE = DALLASA.DB2ZP.ZPDB2.() 
SQLERROR  NOPACKAGE  
CURRENTDATA   YES
DEGREE1  
DYNAMICRULES 
DEFER
NOREOPT   VARS   
KEEPDYNAMIC   NO 
IMMEDWRITEINHERITFROMPLAN
DBPROTOCOLDRDA   
OPTHINT  
ENCODING  EBCDIC(01047)  
PLANMGMT  OFF
PLANMGMTSCOPE STATIC 
CONCURRENTACCESSRESOLUTION   
EXTENDEDINDICATOR
PATH   
 DSNT232I  -DBAG SUCCESSFUL BIND FOR  
PACKAGE = DALLASA.DB2ZP.ZPDB2.()  
 DSN  
  BIND PLAN(DB2ZP) PKLIST(DB2ZP.*) ACT(REP) ISO(CS) CURRENTDATA(YES) 
ENCODING(EBCDIC)
 DSNT252I  -DBAG DSNTBCM1 BIND OPTIONS FOR PLAN DB2ZP 
ACTIONREPLACE 
OWNER JIG 
VALIDATE  RUN 
ISOLATION CS  
ACQUIRE   USE 
RELEASE   COMMIT  
EXPLAIN   NO  
DYNAMICRULES  RUN 
 DSNT253I  -DBAG DSNTBCM1 BIND OPTIONS FOR PLAN DB2ZP 
NODEFER   PREPARE 
CACHESIZE 3072
QUALIFIER JIG 
1   CURRENTSERVER 
CURRENTDATA   YES 
DEGREE1   
SQLRULES