Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
quote:
Originally posted by: mthyvold
I want to pass a query into a function one row at a time in the same way you could pass an array to a function one row at a time. I've read that queries are just CF structures under the hood so I believe it should be possible. I just don't know the syntax to reference a single query row (and all it's variables).
I don't want to pass the whole query to the variable because I would like to do the looping outside the function. The idea is to simplify and standardize the formatting and arrangement of several variables (columns) in a UDF and keep the syntax to use the function simple. Therefore, I'd like to avoid having to do stuff like convert the query to an array. That would defeat the goal of keeping it simple.
Thanks
Magnus
Copy link to clipboard
Copied
Copy link to clipboard
Copied
quote:
Originally posted by: magnusthyvold
Can you explain why not? (other than that AFIK you can't reference and pass a specific query row) Just curious.
Anyway, I guess what I want to do would look more like this:
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
quote:
Originally posted by: Newsgroup User
To be honest, I'd simply pass the whole query (which is done by reference,
so there's not much overhead there), and the row you want as two separate
arguments, then using query["column"][row] notation to access the bits you
want.
--
Adam
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Copy link to clipboard
Copied
For anyone else arrving here QueryGetRow does what you want I believe (introduced in CF11)
Find more inspiration, events, and resources on the new Adobe Community
Explore Now