Multi record form with 'multiple' $_Post field only saves last entry

Hi,

I have a from like the one below, and submitting does work. but only the last three fields of each form row is showing in the db as three new records. while I’m expecting that all 5 column are inserted. so in this case it would mean 15 new records(5 columns X 3 from rows(each containing 3 fields)).

I guess that i’m missing something. Here, but can’t figure out what.

my form:


form structure:

server action(all variables in the record are set as multiple, as this would be a most logical thing to me):
image

Regards,
Nick

Hi Nick,

Can you post a screen shot of your action steps? Do you have a repeat step in there?

Hi @brad,

Yes i do:

image

So are you repeating inputs with same names in your rows?

could you elaborate what you mean?

i’m only repeating the form rows, as i thought that the multiple function would take care of the rest. at least that how i interpreted the docs(https://docs.wappler.io/t/uploading-multiple-files-to-your-server/4412). i just changed to my needs.

The documentation you are pointing to is about file inputs. You cannot use “multiple” like that for text inputs.

So just to confirm - you have a row with several inputs and they have static names. Then you repeat this row with inputs multiple times and want to insert everything in the database?

The names are set like this: record[{{$index}}][date], this was given via the generator.

Each row( marked in first image with borders around each row), is being repeated. the goal is that for each column in a row (columns contain 3 input fields each), a record is created like show in the last image.

destination table:
image

1 Like

Hi I am having this issue where I need to insert the cart items into a sales_information table.
How do I get the repeats to go in there??