Hi,
I was wondering if there is anyway to extract(or load) records of date/timestamp/time datatypes with *timezone* information. My Database fields for date/time have timezone information associated with them, but when I use datastage timestamp/date datatypes it gets truncated.
Other way round, when I use sequential file to load data into database, sequential file does not recognize timestamp/time datatypes with timezone information(say +5-30).
If I use varchar data type to extract time/timestamp fields in sequential file and then try to convert it into timestamp in Modify stage (before supplying it to ODBC stage) then also I could not find any datastage function that supports timezone information.
Timezone support for Date/Timestamp data types
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 39
- Joined: Thu Nov 23, 2006 11:23 pm
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
-
- Participant
- Posts: 39
- Joined: Thu Nov 23, 2006 11:23 pm
Example of data:
"timewithtimezone14","timestampwithouttimezone15","timestampwithtimezone16", "timewithouttimezone17"
"24:00:00-1359","4897-12-31 AD 10:23:54","4897-12-31 AD 13:53:54+05:30","24:00:00",
I can skip the AD/BC part for time being. My database can take input in the format specified above in INSERT SQL queries.
"timewithtimezone14","timestampwithouttimezone15","timestampwithtimezone16", "timewithouttimezone17"
"24:00:00-1359","4897-12-31 AD 10:23:54","4897-12-31 AD 13:53:54+05:30","24:00:00",
I can skip the AD/BC part for time being. My database can take input in the format specified above in INSERT SQL queries.
If I read then as varchar and load into ODBC Connector stage, first I get schema reconciliation errors. I turned schema reconciliation to No in ODBC connector stage, and now it gives some schema rec. warnings and following error message:Perhaps reading them as string data types is a good workaround.
Item #: 15
Event ID: 203
Timestamp:: 2007-10-30 10:55:44
Type: Fatal
User Name: dsadm
Message:: ODBC_Connector_15: Error when checking operator: When binding input interface field "timestampwithouttimezone15" to field "timestampwithouttimezone15": No default type conversion from type "string[max=25]" to type "timestamp".
Error when checking operator: When binding input interface field "timestampwithtimezone16" to field "timestampwithtimezone16": No default type conversion from type "string[max=25]" to type "timestamp".
Error when checking operator: When binding input interface field "timewithouttimezone17" to field "timewithouttimezone17": No default type conversion from type "string[max=12]" to type "time".
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Include CAST functions in your SQL (the derivation columns) to convert to VarChar data type during the extraction phase. This will obviate the warning messages.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.