If you CFPARAM url.id to a non-empty value, then it should work fine.
Although if url.id is required in order to get the content for the page,
shouldn't you just be flat-out requiring the variable to exist, rather than
letting it be optional?

barneyb

> -----Original Message-----
> From: Paul Giesenhagen [mailto:[EMAIL PROTECTED]
> Sent: Thursday, March 13, 2003 2:13 PM
> To: CF-Talk
> Subject: MySQL - Linux cfqueryparam
>
>
> Question,
>
> We ran into this problem on MySQL 3.23.54 / Linux
>
> If no url.id is passed, and you have the following code, it seems
> that if there is no url.id, cfqueryparam adds a ? and then
> requires '' around the cfqueryparam.
>
> Example
>
> <cfparam name="url.id" default="">
>
> SELECT columns....
> FROM table
> WHERE id = <cfqueryparam value="#url.id#" cfsqltype="CF_SQL_VARCHAR">
>
> Now if no url.id isn't passed, it errors out not liking the '?"
> in the WHERE statement ... if you put ' around the
> '<cfqueryparam>' it runs just fine ....
>
> Any thoughts?
>
> Paul Giesenhagen
> QuillDesign
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to