View previous topic :: View next topic
|
Author |
Message |
Amolondhe007 Warnings : 1 New User
Joined: 16 Apr 2007 Posts: 49 Location: Pune
|
|
|
|
Hi,
Please let me know the answer that how we can resolve the timestamp error in DB2? |
|
Back to top |
|
|
n_sri_vas
New User
Joined: 17 Nov 2006 Posts: 6
|
|
|
|
just precompile it once again and be sure the Consistency tokens of Load module and DBRMLIB are same |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
would not one want to re-bind, also? |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
Pre-compiling will not create a load module, need to go thru the compile and link step. |
|
Back to top |
|
|
tarun_bhardwaj
New User
Joined: 18 Jul 2003 Posts: 39 Location: delhi
|
|
|
|
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 |
|
|
ksk
Active User
Joined: 08 Jun 2006 Posts: 355 Location: New York
|
|
|
|
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 |
|
|
tarun_bhardwaj
New User
Joined: 18 Jul 2003 Posts: 39 Location: delhi
|
|
|
|
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 |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
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 |
|
|
Amolondhe007 Warnings : 1 New User
Joined: 16 Apr 2007 Posts: 49 Location: Pune
|
|
|
|
Tarun,
I'm talking about -818 timestamp error.
Thanks. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
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
ibmmainframes.com/faq.php?mode=bbcode |
|
Back to top |
|
|
Amolondhe007 Warnings : 1 New User
Joined: 16 Apr 2007 Posts: 49 Location: Pune
|
|
|
|
Hi Dick,
Could you please explain with the example if you have. Is there any other solution to resolve this? |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
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 |
|
|
tarun_bhardwaj
New User
Joined: 18 Jul 2003 Posts: 39 Location: delhi
|
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
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 |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
Arun,
confusion was created by me.
sorry,
your solution fits the problem. |
|
Back to top |
|
|
|