Database organization

Hello bubble team !

I’m working on a project to create sports programs. To do this, I’ve made questionnaires so that users can answer questions. There would be several sports and therefore a standard questionnaire for each sport. I created a table (type) per sport with a “question” field and put all the questions for the sport in question in it.
I made another one to store the answers, called “Answers”. I added a “question” field to link to my “question” table. The problem is that I don’t know how to save my users’ answers so that they appear in the “answers” table. And I’d also like the answers to be linked to the corresponding question.
That was a long explanation sorry.

If the questions are the same for each form submit then you’d be better off creating a “form_submit” data type and just putting the question fields on that.

User fills out form > create new form_submit > fill in all the data fields.
form_submit “creator” will be the logged in user

Thank you for your answer !
So you mean, i should put each question as a field ?

yes, that’d be how I’d normally do it.

I’d very rarely build it where each question is a data in a table (you may need this if the user was building their own custom form but for a fixed form you don’t need the structure)

okay thank you for your help ! :slight_smile: