Sep-07-2018, 12:30 PM
I cant give lots of codding information on this problem as i am pretty stumped by it. I am using a FLASK framework.
So I have created a table with: X amount of rows and 8 columns. A user will be entering information into the table.
They will have to enter information into multiple rows, so i have added a nice 'Add row' button with javascript so they can do so. Therefore as a programming the table 'size' ( number of rows) is dynamic and such my issue has emerged.
Once they have filled out all the rows ( Its quite likely they create between 5-30 rows) and submit the form I need to save this information to a mysql table.
My best guess is that you will have to loop the sqlalchemy upload query multiple times, uploading 1 row at a time. Similar to how you would upload a CSV file to sqlalchemy.
However I do not know how I would give each input a unique ID and thus allow the form to be uploaded.
So I have created a table with: X amount of rows and 8 columns. A user will be entering information into the table.
They will have to enter information into multiple rows, so i have added a nice 'Add row' button with javascript so they can do so. Therefore as a programming the table 'size' ( number of rows) is dynamic and such my issue has emerged.
Once they have filled out all the rows ( Its quite likely they create between 5-30 rows) and submit the form I need to save this information to a mysql table.
My best guess is that you will have to loop the sqlalchemy upload query multiple times, uploading 1 row at a time. Similar to how you would upload a CSV file to sqlalchemy.
However I do not know how I would give each input a unique ID and thus allow the form to be uploaded.