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

Datatype DATETIME


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

New User


Joined: 11 Jun 2005
Posts: 24

PostPosted: Wed Oct 26, 2005 7:12 pm
Reply with quote

Hi,

Please tell me how to use DATETIME datatype in order to extract date part.Please let me know the format to be used in Workign storage to extract date and whether we can use UNSTRING function to seperate Date and time part.


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

New User


Joined: 15 Jun 2005
Posts: 53
Location: India, Chennai

PostPosted: Thu Oct 27, 2005 4:20 pm
Reply with quote

hi,

you can use the db2 function DATE, TIME to extract date, time from timestamp data type.

(e.g)

EXEC SQl
Select date(current timestamp) into :ws-date from sysibm.sysdummy1
END-EXEC
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 Select numeric portion from CHAR data... DB2 6
No new posts Sticky: CICS Program "DATETIME" CICS 3
No new posts Converting Datatype while adding the ... DFSORT/ICETOOL 6
No new posts DB2 V10 upgrade - DATETIME builtin fu... DB2 2
No new posts PL/I builtin function DATETIME PL/I & Assembler 13
Search our Forums:

Back to Top