It looks to me like you have found a CF bug.  The CFQUERY tag is trying to
be too smart by protecting you from yourself and wrapping your query value
in single quotes.

If this indeed the case, what happens if you do this:

<cfset sWhere = "where office = 90">

This may be a valid workaround.

Terry


On Thu, 28 Feb 2002, Glenn Shukster wrote:

> In creating a complex query I wanted to first put all the where clause
> into a string.  Then when its done put it in the query.
>
> simple example.
>
> <cfSet sWhere = "where office = '90'">
>
> <cfQuery ...>
> Select * from MyTable
> #sWhere#
> </cfQuery>
>
> The query bombs and in the debug code it shows two sets of quotes around
> 90.
> office = ''90''
>
> What am I doing wrong?
>

-- 
Terry Fielder
Network Engineer
Great Gulf Homes / Ashton Woods Homes

-
You are subscribed to the CFUGToronto CFTALK ListSRV.
This message has been posted by: [EMAIL PROTECTED]
To Unsubscribe, Please Visit and Login to http://www.CFUGToronto.org/
Manager: Kevin Towes ([EMAIL PROTECTED]) http://www.CFUGToronto.org/
This System has been donated by Infopreneur, Inc.
(http://www.infopreneur.net)

Reply via email to