...
Code Block | ||
---|---|---|
| ||
db_demo=# select * from public.item; key | document | properties | text -----+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------+-------------------- 1 | {"name": "DocumentExample", "elements": {"additionalProp1": {"name": "ElementExample 1", "tags": ["tag1"]}, "additionalProp2": {"name": "ElementExample 2", "tags": ["tag2"]}, "additionalProp3": {"name": "ElementExample 3", "tags": ["tag3"]}}} | {"additionalProp1": "Val 10", "additionalProp2": "11", "additionalProp3": "12"} | This is an example (1 row) |
Table of comparison
Type | DataStore | Validation | Query | Index |
---|---|---|---|---|
longtext | MariaDB | SELECT | Yes | No |
longtext | PostgreSQL | No | No | No |
json | PostgreSQL | INSERT / UPDATE | Yes | No |
jsonb | PostgreSQL | INSERT / UPDATE | Yes | Yes |
Conclusion
My suggestion as shown below is three options:
...