Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add more flexibility for data types #452

Open
variety01 opened this issue Oct 11, 2023 · 2 comments
Open

Add more flexibility for data types #452

variety01 opened this issue Oct 11, 2023 · 2 comments

Comments

@variety01
Copy link

Currently i can not build complex schemas with different denormalizations. Now it is strictly relational. So i suggest you to add custom data types and lists/maps.

@huyphung1602
Copy link
Collaborator

huyphung1602 commented Oct 12, 2023

Hi there,

Thank you for sharing your issue with us.

Can you give us some example of your use-case and which data type list/maps that you want support?

Best regards,
Huy Phung

@variety01
Copy link
Author

Lists and maps are necessary for non-relational databases.
A simple example of denormalization in relational is to create a list of any type in A to avoid joins. It works well if this list won't be large and is primarily used for read queries. An example could be a "books" table with field "authors" as list of strings .

Also, using JSON schema definitions is a good idea. We can store different JSONs in the "events" table but with clearly defined possible schemas. For example: "type EventCreated," "type EventCanceled," and a table "events" with a "event_data" field of "json[EventCreated, EventCanceled]" type.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants