0

Hi CF People
I have a query:

<cfquery name="getspecial" datasource="#dsn#"> 
SELECT ID, category, product, special 
FROM products 
WHERE special = 'Yes' 
</cfquery>

If i do a cfdump of this query it shows that ??? is the category.

However when i try asnd use this variable in a url link back to another page:

<cfoutput>#getspecial.category#</cfoutput>

I gat an error; that Element CATEGORY is undefined in GETSPECIAL.

How can this be if the category is selected in the query how come i cant then use it as a link variable

any help would be appreciated
cheers and thanks in advance
Grabit

Read more: http://www.easycfm.com/coldfusion/forums/viewmessages.cfm?Forum=12&Topic=15163#ixzz1Oj4yo4LE

Edited by Ezzaral: Added code tags. Please use them to format any code that you post.

2
Contributors
1
Reply
2
Views
6 Years
Discussion Span
Last Post by cfwebdeveloper
0

However when i try asnd use this variable in a url link back to another page:

Queries do not go from page to page. If you need information to be passed to another page set the variables as session variables or pass the unique id as the URL variable and query the database where id = #url.id#.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.