ODBC TimeStamp

Database

ODBC TimeStamp

Hi Guys,

It's my first topic here, I'm new on Teradata and we are facing a problem with ODBC with Timestamp. Let me explain the situation:

We have a Oracle GoldenGate running on IBM AIX replicating transactions to our Teradata 15.00. In our Teradata we have a Table that has a column with TIMESTAMP(6) WITH TIME ZONE NOT NULL.

When we receive the records from the GoldenGate, the output for this column in this way: 

28 I 2016-02-20 23:00:20.065771-00:00

27 I 2016-02-20 23:59:58.065771-00:00

29 I 2016-02-21 01:21:52.065024-00:00

30 I 2016-02-21 01:21:52.065024-00:00

Remember that the source(GoldenGate, there is no timezone).

But, the output should be this way:

28 I 2016-02-20 23:00:20.065771-02:00

27 I 2016-02-20 23:59:58.065771-02:00

29 I 2016-02-21 01:21:52.065024-03:00

30 I 2016-02-21 01:21:52.065024-03:00

I've found that ODBC has some limitations with Timezone, do you guys have sometips with this issue?

Thank you so much,

2 REPLIES
Junior Contributor

Re: ODBC TimeStamp

See if this works.

On a session level set the timezone to your local daylight saving timezone:

SET TIME ZONE 'America Brazil';

and then remove the '-00:00' and cast like this:

CAST(SUBSTRING(col FROM 1 FOR 26) AS TIMESTAMP) AT LOCAL

Re: ODBC TimeStamp

Hello Dieter,

Did not work.. any other ideia, for example, modify user to set a timezone or use a profile with a timezone to the user?