Capital letters vs. lower case.
Your 'hardcode' example used a lowercase letter, while your examples here
have an uppercase letter.
If changing the uppercase in the variable to a lowercase 'does' result in
the expected solutions, then I would suggest changing the 'case' of both
sides of the equality.
<cfquery name="data" dbtype="query">
select * from session.usersData
<cfif isDefined('url.alpha')>
where LOWER(username) LIKE '#Lcase(url.alpha)#%'
</cfif>
order by #sortKey# #sortOrder#
</cfquery>
--
William E. Seiter
Have you ever read a book that changed your life?
Go to: www.winninginthemargins.com
Enter passkey: goldengrove
Web Developer / ColdFusion Programmer
http://William.Seiter.com
-----Original Message-----
From: Walter Conti [mailto:[EMAIL PROTECTED]
Sent: Monday, March 03, 2008 6:09 AM
To: CF-Newbie
Subject: Re: Query-of-Query and MySQL
<cfdump var = "#data.recordcount#"> returns zero records.
The query has not been simplified.
I have tried various values for url.alpha: "A,B,C,D ..."
>When you dump the recordcount (<cfdump var="#date.recordcount#">
>
>Does it say '0' or does it say the variable is undefined?
>
>Also, is this the exact query that is in your code or is it 'simplified'
for
>this list?
>
>--
>William E. Seiter
>
>Have you ever read a book that changed your life?
>Go to: www.winninginthemargins.com
>Enter passkey: goldengrove
>
>Web Developer / ColdFusion Programmer
>http://William.Seiter.com
>
>Thank You William,
>
>The var "url.alpha" is read properly up to the line of <cfquery ...
>Even if I create <cfparam name="url.alpha" default="A"> the cfquery
>does not recognize it.
>I am at a loss ...
>
>Walter Conti
>
>-----------------
>
>
>>Add this line directly before your query.
>><cfdump var="#url.alpha#" label="url.alpha">
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w
Archive:
http://www.houseoffusion.com/groups/CF-Newbie/message.cfm/messageid:3369
Subscription: http://www.houseoffusion.com/groups/CF-Newbie/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.15