Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Error-Getting year out of timestamp

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1806
Location: NY,USA

PostPosted: Fri Mar 22, 2013 1:16 am    Post subject: Error-Getting year out of timestamp
Reply with quote

Code:
EXEC  SQL                       
  SELECT YEAR(CURRENT TIMESTAMP)
       INTO :WS-TIMESTAMP-YEAR 
  FROM SYSIBM.SYSDUMMY1         
END-EXEC                               


WS-TIMESTAMP-YEAR is definied as x(4).

Is it valid to use it in the application programming?

This works fine with SPUFI and other tools.

but in the application programming I am getting below error,

Code:
====== NEW PAGE ========                                                       
 ERROR ON SETTING TIMESTAMP                                                     
 IGZ0020S A logic error occurred.  Neither FILE STATUS nor a declarative was spe
          AAABD002 at relative location X'8DEA'.  The status code was 42.       
 CEE3250C The system or user abend U1020 R=00000000 was issued.                 
          From compile unit CEEWUCHA at entry point CEEWUCHA at compile unit off
           at address 209779F4.     


Resolution:

Code:
Programmer Response:  Check operation request for the file.   
                                                               
System Action:  The application was terminated.               


Can anyone please suggest.
Back to top
View user's profile Send private message

Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Fri Mar 22, 2013 1:29 am    Post subject:
Reply with quote

The value returned for the YEAR function is a large integer!
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1806
Location: NY,USA

PostPosted: Fri Mar 22, 2013 2:04 am    Post subject:
Reply with quote

Thanks Craq.
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 IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts FTP Skip or ignore error and process ... AJAYREDDY All Other Mainframe Topics 3 Wed Sep 27, 2017 8:12 pm
No new posts Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am
No new posts Fetch Previous month & year in MM... girishb2 DFSORT/ICETOOL 3 Thu Sep 21, 2017 9:54 pm
No new posts FUSE - IBM MQ - CICS integration error Kevin Vaz CICS 1 Mon Sep 18, 2017 4:31 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us