Hi guys wanted to get some feedback on the way I have been using In my first app I am using both array (text) and jsonb columns. I am using these instead of additional DB tables since the structure in each record will be different and I do not intend to search into them.
The array text column is used to:
The JSONB columns are used to manage form templates and values:
One columns is used to store form templates created using formbuilder.js in the tforms table. The other is used to store both form and data in the actual consultation table: when a consultation is created, the template from the forms table is saved to the consultation form column. From this point on every time the consultation is accessed the form and inputs are accessed/saved in the local column. This way the form template can be modified for future consultations and the old data is preserved (i need to add a function that allows users to add newly added fields to existing consultations if required).
All works fine for now on the prototype. However, I wonder if anyone would have done things in a different way..
Thanks in advance for your time!
Join 24,647+ developers who get early access to new screencasts, articles, guides, updates, and more.