I have a query which is based on an input of a list of data, separated by semicolons. When running the query the output automatically goes into the order of the data in the first column. Is it possible to output the data in the order of the input list? Example images below:
Input list:

Report output order:

Help is very much appreciated.
Request clarification before answering.
You can create a custom sort order as shown toward the end of this video. The limitation to that method is that your custom sort order values are limited to what is present within the data at the moment you define it.
If you are strictly looking to sort the data in the order or your parameter you could create a variable that looks for the position of the object in question in your prompt response and sort by that.
First create a variable to capture that semi-colon separated list of prompt response values. I called mine Var Prompt Response and defined it as follows...
=UserResponse("pmEnter value(s) for State") + ";"
You have to append that extra semi-colon at the end to address the possibility where object values you are searching for have instances where one value is contained within another value like this...
12340;9876;1234So if we add a semi-colon to the end we can look for where the object you are prompting for plus a semi-colon occurs in the prompt string. I'll call that Var Prompt Index with the following definition...
=Pos([Var Prompt Response]; [State] + ";")Add Var Prompt Index to your table as the first column and allow the default sort to occur or put it else where in the table and explicitly define your sort on it.

You can hide Var Prompt Index if you want.

Hope that works for you,
Noel
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 4 | |
| 4 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.