parthasarathi_r
09/15/2021, 8:52 AMtarget-redshift | psycopg2.errors.UndefinedColumn: column "_id" named in key does not exist
After analyzing, found that the tap produced below schema
{"type": "SCHEMA", "stream": "mongodb_document", "schema": {"type": "object"}, "key_properties": ["_id"]}
and, target-redshift tries to create a table with this schema. Since "_id" is mentioned key, it searches for this field under the schema and gets failed.
Question - Is it possible to manually update the schema? In singer, there would be catalog.json. In meltano documentation, it is mentioned as it will be handled internally. Could you please let me know if there is any way to update the schema?taylor
09/15/2021, 1:58 PMtaylor
09/15/2021, 1:59 PMkey_properties
to an empty list as well to indicate there's no primary key.francis_niu
09/16/2021, 9:49 AMschema
extra (https://meltano.com/docs/integration.html#overriding-schemas), then meltano will generate correct catalog.json.
2. The tap-mongodb
default variant is out of maintenance, it always generate schema from data rows and doesn't follow the schema in catalog.json. So I forked and modified tap-mongodb
to use specified schema.