Forum Discussion

expat's avatar
expat
Occasional Contributor
12 years ago

iterate datasource, multiple rows single request

I searched and searched the board but cannot seem to come to a solution to my issue. Groovy is something i am not yet familiar with but expect i will need in the future.

The challenge i have:

I have multiple instances of the same form in the request, but need each instance of the form to use a different row. For example I have

first name:
last name:
Class:

first name:
last name:
Class:

in the same request. If i use the datasource and point to the corresponding data i.e. ${DataSource#firstname}, {DataSource#lastname}, {DataSource#class}, then when i send the request it will use the same first name on each of the values and only iterate it when the request is sent on the second loop. What i would like, is to use row 1 for the first form and row 2 for the second, then on the loop use row 3 and 4. There will be up to 100 of these in a single request, so creating seperate datasources does not make sense. So the first iteration sends the 1st 100 rows and the second then starts on row 101 and sends the next set etc.

Hopefully that makes sense, as i am at my whits end trying to get this to work and ran out of avenues to persue.

Expat.

13 Replies