I need to use cfloop
to insert records.
There's a form a customer fills out. They add an item from a dropdown list, and then enter in a quantity in a text box. Normally, the quantity is only between 1 and 5.
I need to run a loop to insert the records one at a time with a unique Item ID for each with a quantity of 1.
For example, if they add Specific Item 5 with a quantity of 4, I need 4 records inserted into the table with a qty of 1 each. What I really want more than the answer here is the thought process of how I'd come to that going forward without having to ask.