I've been tasked with amending a site written by someone
else, and i've got a very strange problem with a particular query.
When i run the query in Query Analyser (replacing the
variables with their corresponding values) it all works fine, and
even copy-pasting it out of Profiler and into Analyser works fine,
but running it in the CF page produces weird results:
It claims not to be a query object, but has a recordcount
property
When i cfdump it, i get "1"
Accessing SelectForSend.article_id works fine as a single
value (the correct value of the first row returned) but attempting
to convert that using ValueList() produces:
The column article_id is not present in the query named
SelectForSend. It is likely that you have misspelled the name of
the column.
Attempting to use the query in a loop or output gives me
Attribute validation error for tag cfloop.
The value of the attribute query, which is currently
"SelectForSend", is invalid.
This all works fine on the live site on its CF5 server, but
not on my testing server on MX7.
I've attached the offending query here, if anyone has any
pointers on this it would be very much appreciated!! Example values
for the vars in the query are as follows:
SelectSubscribers.EID is a string equal to the user's
username
maxId is a int (1750, for example)
(Apologies for the formatting, or lack thereof!)