Boggdan Barrientos
12/28/2021, 11:45 PMjsonb_set
,
I'm writing like, but nothing is updated.
UPDATE jobs SET config = jsonb_set(config, '{"sync":{"state"}}'::jsonb, '{"state": {"cdc": false, "streams": [{"cursor": "2021-10-29T00:00:00Z", "stream_name": "PROMOCIONESGENERADAS", "cursor_field": ["Fecha"], "stream_namespace": "CENTRALIZADOR"}]}}', false) WHERE id = 1611;
I think that I'm writting wrong the path, what the correct way to do it?
I think that is most a postgres question, but I hope find some guide here. Thanks.Boggdan Barrientos
12/28/2021, 11:45 PM{
"sync":{
"state":{
"state":{
"cdc":false,
"streams":[
{
"cursor":"2021-10-31T00:00:00Z",
"stream_name":"PROMOCIONESGENERADAS",
"cursor_field":[
"Fecha"
],
"stream_namespace":"CENTRALIZADOR"
}
]
}
},
"prefix":"",
"namespaceFormat":"raw_test",
"operationSequence":[
],
"sourceDockerImage":"airbyte/source-oracle:0.3.8",
"namespaceDefinition":"customformat",
"sourceConfiguration":{
"sid":"stage",
"host":"****",
"port":****,
"schemas":[
"CENTRALIZADOR"
],
"password":"****",
"username":"****",
"encryption":{
"encryption_method":"unencrypted"
},
"tunnel_method":{
"tunnel_method":"NO_TUNNEL"
}
},
"resourceRequirements":{
},
"destinationDockerImage":"airbyte/destination-redshift:0.3.20",
"configuredAirbyteCatalog":{
"streams":[
{
"stream":{
"name":"PROMOCIONESGENERADAS",
"namespace":"CENTRALIZADOR",
"json_schema":{
"type":"object",
"properties":{
"Id":{
"type":"number"
},
"Hora":{
"type":"string"
},
"Fecha":{
"type":"string"
},
"IdCajas":{
"type":"number"
},
"Cantidad":{
"type":"number"
},
"CodigoPago":{
"type":"string"
},
"Generacion":{
"type":"string"
},
"IdEmpresas":{
"type":"number"
},
"IdUsuarios":{
"type":"number"
},
"IdSucursales":{
"type":"number"
},
"IdPromociones":{
"type":"number"
},
"MontoPromocion":{
"type":"number"
},
"IdTransacciones":{
"type":"number"
},
"MontoTransaccion":{
"type":"number"
},
"CantidadPromocion":{
"type":"number"
},
"IdPromocionesCriterios":{
"type":"number"
}
}
},
"default_cursor_field":[
],
"supported_sync_modes":[
"full_refresh",
"incremental"
],
"source_defined_primary_key":[
]
},
"sync_mode":"incremental",
"primary_key":[
],
"cursor_field":[
"Fecha"
],
"destination_sync_mode":"append"
}
]
},
"destinationConfiguration":{
"host":"*****",
"port":5439,
"schema":"public",
"database":"raw",
"password":"******",
"username":"airbyte_user",
"access_key_id":"*****",
"s3_bucket_name":"unibi-airbyte-staging",
"s3_bucket_region":"*****",
"secret_access_key":"*****"
}
},
"configType":"sync"
}
[DEPRECATED] Marcos Marx
Javier Llorente Mañas
12/30/2021, 5:06 PM