farshad_ghorbani
09/28/2022, 3:27 AMsource: mysql 5.7
target: big-query
Meltano: V2.7.1
OS: ubuntu 20.04
Python: Python 3.8.10
Do you have any idea, how can I fix this error, because in all of tables I have this error and also I can’t update source database?
CRITICAL 400 reason: invalid, errors: Error while reading data, error message: JSON table encountered too many errors, giving up. Rows: 4; errors: 1. Please look into the errors[] collection for more details.;Error while reading data, error message: JSON processing encountered too many errors, giving up. Rows: 4; errors: 1; max bad: 0; error percent: 0;Error while reading data, error message: JSON parsing error in row starting at position 83138: Couldn't convert value to timestamp: Day 0-0-0 does not exist for timestamp: 0000-00-00 00:00:00 Field: updated_at; Value: 0000-00-00 00:00:00christoph
09/28/2022, 3:44 AM0000-00-00 00:00:00 which causes some problems somewhere in Meltano (not sure where).
What I did is, I just dropped any fields where this timestamp showed up in the MySQL stream like this:
mappers:
- name: transform-field
variant: transferwise
mappings:
- name: transform-field-set-null
config:
transformations:
- tap_stream_name: yourmysqlstreamname
field_id: TheFieldName
type: SET-NULL
when:
- column: TheFieldName
equals: "0000-00-00 00:00:00"christoph
09/28/2022, 3:48 AMfarshad_ghorbani
09/28/2022, 4:01 AMfarshad_ghorbani
09/28/2022, 4:01 AMfarshad_ghorbani
09/28/2022, 4:13 AMfarshad_ghorbani
09/28/2022, 4:14 AMthomas_briggs
09/28/2022, 1:00 PMthomas_briggs
09/28/2022, 1:01 PMfarshad_ghorbani
09/28/2022, 4:52 PMfarshad_ghorbani
09/28/2022, 4:53 PMfarshad_ghorbani
09/28/2022, 4:55 PMthomas_briggs
09/28/2022, 6:08 PMthomas_briggs
09/28/2022, 6:10 PMfarshad_ghorbani
09/28/2022, 8:15 PMfarshad_ghorbani
09/28/2022, 10:09 PM- name: meltano-map-transformer
variant: meltano
pip_url: git+<https://github.com/MeltanoLabs/meltano-map-transform.git>
mappings:
- name: alias-tables
config:
stream_maps:
schema-table:
__alias__: table