IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Bind process


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Chandan1993

New User


Joined: 21 May 2017
Posts: 6
Location: India

PostPosted: Wed Mar 13, 2019 10:33 pm
Reply with quote

as i know DSNHPC utility separates DB2 and cobol code and creates Token as timestamp. and during run time when timestamp is mismatch then we get -805 abend.
but now my question is if i compiled my program today and forgets to bind.If bind tomorrow then timetamp for cobol loadmodule and db2 would be different and code should through -805 abend. but in my case code ran properly..why ?
why i didn't get error as -805

can somebody clarifies my doubt please.
Back to top
View user's profile Send private message
daveporcelan

Active Member


Joined: 01 Dec 2006
Posts: 792
Location: Pennsylvania

PostPosted: Wed Mar 13, 2019 10:42 pm
Reply with quote

The contoken for the load module is created at compile time.

The Bind, of the Load Module and DBRM can be done whenever. This creates the Package, with the proper Contoken matching the Load module.

It is a mismatch of the contoken between the Package and the Load module that issues the -805 sqlcode.
Back to top
View user's profile Send private message
Chandan1993

New User


Joined: 21 May 2017
Posts: 6
Location: India

PostPosted: Wed Mar 13, 2019 10:46 pm
Reply with quote

daveporcelan wrote:
The contoken for the load module is created at compile time.

The Bind, of the Load Module and DBRM can be done whenever. This creates the Package, with the proper Contoken matching the Load module.

It is a mismatch of the contoken between the Package and the Load module that issues the -805 sqlcode.


could you please make more clear. Are you saying i should get -805 in my case ?
Back to top
View user's profile Send private message
daveporcelan

Active Member


Joined: 01 Dec 2006
Posts: 792
Location: Pennsylvania

PostPosted: Wed Mar 13, 2019 10:57 pm
Reply with quote

Quote:
If bind tomorrow then timetamp for cobol loadmodule and db2 would be different and code should through -805 abend.


This is a false assumption.

The timestamp for the load module and dbrm are created at compile time.

The Bind sees that they match. It uses a second indicator called a contoken, while creating the package. This contoken ties the load module and the package together. The timestamp is no longer used after the bind is done.

At run time the contoken of the load module and the package are checked to see if they match. In your case they do, thus why it worked.

Apparently, you were not provided proper db2 training.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3051
Location: NYC,USA

PostPosted: Thu Mar 14, 2019 3:33 am
Reply with quote

Also, you need to be able to differentiate between-818 and -805 clearly. Please read DB2 manual and link is provided at the top of this site.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts process statement for SUPREC, CMPCOLM... TSO/ISPF 4
No new posts JCL for pl1 db2 precompile, compile a... JCL & VSAM 4
No new posts How to process dependent file based o... JCL & VSAM 8
This topic is locked: you cannot edit posts or make replies. How to process gdg in rexx program wh... CLIST & REXX 12
No new posts Process Last Key of a record based on... DFSORT/ICETOOL 5
Search our Forums:

Back to Top