Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Cloud Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Cloud.

I am having an issue with importing data from mysql where all the timestamp values are ahead by 2 hours, i know this because when i look at the data from the workbench its behind by 2 hours.

KhulekaniJ
5 - Atom

select * from tablename where timestamp_local between 

'2022-01-01' and '2022-04-30'  i used this statement for the workbench and in trifacta

1 REPLY 1
MJebeli_Tri
Alteryx Alumni (Retired)

Good morning,

 

Trifacta won't be changing the value of the timestamp returned from the MySQL database unless specified in transformation.

 

I think our first task should be finding out what timezone the MySQL database is storing the date fields. There is a good discussion on it here: https://stackoverflow.com/questions/2934258/how-do-i-get-the-current-time-zone-of-mysql

 

Once we have that, we can use that information to convert the timestamp to the target timezone we want. You could either do the conversion in the SQL (select convert_tz(now(),@@session.time_zone,'+03:00')) or use the Trifacta timezone recipe steps to do that (https://docs.trifacta.com/display/SS/EXAMPLE+-+Time+Zone+Conversion+Functions)

 

I hope this helps.