Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Odd Timestamp behaviour?

Status
Not open for further replies.

ericmx

Technical User
Nov 5, 2003
3
GB
Net Express 4.0 on Windows XP
Using ESQL options to establish ODBC connection to Connect DB2 which links to a remote IBM Mainframe

Obtaining a timestamp.

Neither mainframe format
SET :x = CURRENT TIMESTAMP
0r UDB format
VALUES ( CURRENT TIMESTAMP ) INTO :x
work. Both result in SQLCODE -104 (Illegal Symbol)

SELECT CURRENT TIMESTAMP INTO :x FROM SYSIBM.SYSDUMMY1

is successful in retrieving a timestamp.

However the timestamp is obtained as:
"yyyy-mm-dd hh:mm:ss.xxxxxx"

This format is rejected by DB2 when used to update the DB. DB2 expects "yyyy-mm-dd-hh.mm.ss.xxxxxx"

I thought this may be due to national language characteristics (the mainframe is in a different country), but I haven't found anyone that can confirm this.

help :)

thank you

Eric
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top