Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How we can resolve the timestamp error in DB2?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
Amolondhe007
Warnings : 1

New User


Joined: 16 Apr 2007
Posts: 50
Location: Pune

PostPosted: Mon Nov 10, 2008 12:19 pm    Post subject: How we can resolve the timestamp error in DB2?
Reply with quote

Hi,

Please let me know the answer that how we can resolve the timestamp error in DB2?
Back to top
View user's profile Send private message

n_sri_vas

New User


Joined: 17 Nov 2006
Posts: 6

PostPosted: Mon Nov 10, 2008 12:27 pm    Post subject:
Reply with quote

just precompile it once again and be sure the Consistency tokens of Load module and DBRMLIB are same
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Mon Nov 10, 2008 1:19 pm    Post subject:
Reply with quote

would not one want to re-bind, also?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Mon Nov 10, 2008 1:20 pm    Post subject:
Reply with quote

Pre-compiling will not create a load module, need to go thru the compile and link step.
Back to top
View user's profile Send private message
tarun_bhardwaj

New User


Joined: 18 Jul 2003
Posts: 39
Location: delhi

PostPosted: Mon Nov 10, 2008 2:13 pm    Post subject: Reply to: How we can resolve the timestamp error in DB2?
Reply with quote

First of all, which SQL error code are you talking about ? the -805 of -181 ? Both of them need a different treatment.
Back to top
View user's profile Send private message
ksk

Active User


Joined: 08 Jun 2006
Posts: 356
Location: New York

PostPosted: Mon Nov 10, 2008 2:28 pm    Post subject:
Reply with quote

Tarun,

-805 is not related to Timestamp error.

-818 Timestamp mismatch or
-180/-181 Bad data in Date/Time/Timestamp
Value for DATE, TIME, TIMESTAMP is invalid
Back to top
View user's profile Send private message
tarun_bhardwaj

New User


Joined: 18 Jul 2003
Posts: 39
Location: delhi

PostPosted: Mon Nov 10, 2008 2:31 pm    Post subject: Reply to: How we can resolve the timestamp error in DB2?
Reply with quote

KSK,

I know that but the responses that have been posted to the original query have been talking about mismatched consistency token (which has to do with -805). Thats why we first need to know the exact SQL error code that Amol is facing.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Mon Nov 10, 2008 3:03 pm    Post subject:
Reply with quote

tarun_bhardwaj,

good catch. I am glad you were persistant with your statements.

another example of posters trying to help when the original question is poorly worded.
Back to top
View user's profile Send private message
Amolondhe007
Warnings : 1

New User


Joined: 16 Apr 2007
Posts: 50
Location: Pune

PostPosted: Mon Nov 10, 2008 4:07 pm    Post subject: Reply to: How we can resolve the timestamp error in DB2?
Reply with quote

Tarun,

I'm talking about -818 timestamp error.

Thanks.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Mon Nov 10, 2008 4:23 pm    Post subject:
Reply with quote

your host variable is not a valid timestamp. fix it.

if you are unable to do so, or it is not that simple,
would help us if you would supply your sql,
please use code/code tags
http://ibmmainframes.com/faq.php?mode=bbcode
Back to top
View user's profile Send private message
Amolondhe007
Warnings : 1

New User


Joined: 16 Apr 2007
Posts: 50
Location: Pune

PostPosted: Mon Nov 10, 2008 4:43 pm    Post subject: Reply to: How we can resolve the timestamp error in DB2?
Reply with quote

Hi Dick,

Could you please explain with the example if you have. Is there any other solution to resolve this?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Mon Nov 10, 2008 5:06 pm    Post subject:
Reply with quote

Amol,

your sql (which you did not provide) references
  • a host variable which DB2 has decided should contain a timestamp. The value contained in your host variable is not a valid timestamp.
  • a function generated timestamp which, when resolved, is not a valid timestamp.


if you would supply your sql, we could probably tell you which host variable is in error.
If you would supply the values contained in your host variables, our guesses would 'probably' be more exact.
Your SQL would be a very good example to start with.
Back to top
View user's profile Send private message
tarun_bhardwaj

New User


Joined: 18 Jul 2003
Posts: 39
Location: delhi

PostPosted: Mon Nov 10, 2008 5:14 pm    Post subject: Reply to: How we can resolve the timestamp error in DB2?
Reply with quote

You can go thru the folling links to resolve your problem

http://www.ibmmainframes.com/about621.html
http://www.ibmmainframes.com/viewtopic.php?t=2535&highlight=818

Best wishes,
Tarun
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2278
Location: @my desk

PostPosted: Mon Nov 10, 2008 6:39 pm    Post subject:
Reply with quote

Quote:

Tarun,

I'm talking about -818 timestamp error.

Thanks.
Dick,

Amol is facing sqlcode = -818 which explains the below reason.
Quote:
-818 THE PRECOMPILER-GENERATED TIMESTAMP x IN THE LOAD MODULE IS DIFFERENT FROM THE BIND TIMESTAMP y BUILT FROM THE DBRM z

Programmer Response: BIND the application again, using the DBRM for the application program that matches the object module.


But the discussion here seems to be about correcting the host variable/SQL. Confused icon_rolleyes.gif
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Mon Nov 10, 2008 7:20 pm    Post subject:
Reply with quote

Arun,
confusion was created by me.

sorry,

your solution fits the problem.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts DB2 Program abending without giving a... rahulgarg14 DB2 7 Mon May 29, 2017 8:10 pm
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
No new posts IDC2902I Error tzeche ABENDS & Debugging 2 Tue Mar 28, 2017 11:39 am
No new posts Need help with below DB2 error ashek15 DB2 3 Sat Mar 18, 2017 5:56 am
No new posts FINDREP Syntax Error seahawk789 DFSORT/ICETOOL 4 Thu Mar 09, 2017 10:11 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us