Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
ffanali0804
Contributor
Contributor

Wrong date type in Google Bigquery

hello,

I created a Talend job that do these actions:

  1. call a SQL Server SP and fill a table
  2. read from a SQL Server Table
  3. write a Parquet file
  4. upload the file in Google Storage
  5. exec a sql statement in a tBigQuerySQLRow that load data from Parquet file to a BiqQuery table.

The table has some DATE data-type fields like these "yyyy-MM-dd" and if I check the schema of the parquet file, I see that the fields are of type Date (see screen attached). But when I check the parquet file the data type are transformed into timestamps and the bigquery table has timestamp fields too.

My question: is there a solution to write the field in Date rather than Timestamp? 

Thanks a lot.

Labels (3)
6 Replies
Anonymous
Not applicable

Your database is probably holding the dates with their timestamps, but you are viewing them without their timestamps. People often confuse what their query analyser application shows with what the DB is holding. When you create your Parquet file, you will need to format the dates appropriately so that the timestamps are not included. Can you show the job that creates your Parquet file?

ffanali0804
Contributor
Contributor
Author

hi @Richard Hall​ 

I attached the imagine up 🙂

Anonymous
Not applicable

What does your Parquet schema look like?

ffanali0804
Contributor
Contributor
Author

is the same as that of the input table :

0695b00000WwacPAAR.png

Anonymous
Not applicable

I have looked into this and I see the issue. The only type of "date" field that is used in Talend is the Java Date class. This always contains time. It holds everything. The formatting of Date columns simply deal with the human readable presentation of that data. The column itself does not lose any data. As such, in Parquet it will be creating a Timestamp field.

 

There is a feature request that I have found for this. But it is not ready for implementation yet.

ffanali0804
Contributor
Contributor
Author

hi @Richard Hall​ 

it is really a pity that there is no solution. The only one I can think of is to copy the data in bigquery to a new table by making the appropriate casts.

Thank you very much for your support. 💪