avram
avram copied to clipboard
Make updating JSON columns easier with jsonb_set
https://dev.to/deepika_banoth/how-to-use-jsonbset-function-in-postgresql-35eo
This function is pretty cool. I think we can utilize it to make updating JSON column data easier.
jsonb_insert() is another cool one https://www.sqliz.com/postgresql-ref/jsonb_insert/
Here's some docs I found on the difference between these two https://docs.yugabyte.com/preview/api/ysql/datatypes/type_json/functions-operators/jsonb-set-jsonb-insert/
It looks like jsonb_set has a create_if_missing feature, and jsonb_insert has a insert_after feature...