If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > iseries issue

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-16-09, 03:24
ratheeshknair ratheeshknair is offline
Registered User
 
Join Date: Jan 2009
Posts: 153
iseries issue

Hi Experts,

We have an issue with db2 in iseries as we are not able to get date before 1940.We are getting the value as NULL but stil the data is there in database.

Please Help
TIA
Reply With Quote
  #2 (permalink)  
Old 09-16-09, 04:05
tonkuma tonkuma is offline
Registered User
 
Join Date: Feb 2008
Location: Japan
Posts: 2,193
iSeries DB2 Universal Database for iSeries SQL Reference Version 5:
Quote:
Date
A date is a three-part value (year, month, and day) designating a point in time
under the Gregorian calendar16, which is assumed to have been in effect from the
year 1 A.D. The range of the year part is 0001 to 9999. The date formats *JUL,
*MDY, *DMY, and *YMD can only represent dates in the range 1940 through 2039.

.....
So, you may want to use the date format *ISO, *USA, *EUR or *JIS.
Reply With Quote
  #3 (permalink)  
Old 09-17-09, 05:21
ratheeshknair ratheeshknair is offline
Registered User
 
Join Date: Jan 2009
Posts: 153
How to use the date format date format *ISO, *USA, *EUR or *JIS.
Reply With Quote
  #4 (permalink)  
Old 09-17-09, 09:49
tonkuma tonkuma is offline
Registered User
 
Join Date: Feb 2008
Location: Japan
Posts: 2,193
Quote:
How to use the date format date format *ISO, *USA, *EUR or *JIS.
I don't know exactly.
Please see manuals including "DB2 Universal Database for iSeries SQL Reference Version 5".
The SET OPTION statement may help you.
Reply With Quote
  #5 (permalink)  
Old 10-08-09, 01:47
ratheeshknair ratheeshknair is offline
Registered User
 
Join Date: Jan 2009
Posts: 153
Thanks Tonkuma,

Can you please tell me where and how to execute the set option i tried
SET OPTION DATFMT=ISO and getting error
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On