I ytird yjr following but it still fails

<cfparam type="string" name="tempVar">

<cfset tempVar = URL.thisProduct>

<cfoutput>#tempvar#</cfoutput>

<cfquery name="getProductDetail" dbtype="query">
SELECT ProductID, ProductName, Price, LongDescription, LargeImage,Company
FROM getCatalog
WHERE ProductID = '#URL.thisProduct#'
</cfquery>
----- Original Message ----- 
From: "Charlie Griefer" <[EMAIL PROTECTED]>
To: "CF-Talk" <[email protected]>
Sent: Tuesday, August 23, 2005 8:37 PM
Subject: Re: URL string not working... HELP!


> a <cfqueryparam> (with the appropriate cfsqltype) around the
> URL.thisProduct should fix things up.
>
> and/or you could wrap the var in a toString() ?
>
>
> On 8/23/05, Sharon Creese <[EMAIL PROTECTED]> wrote:
> > I just tried that and it did not work. I think what is happenning is
that
> > when the value is passed to the query it does not like the the - when
the
> > other parts of the string are numbers so it tries to do math though it
is a
> > string.
> >
> > I am doing a query and then running another query against the first's
> > results
> > <cfquery name="getcatalog" datasource="#Request.App.datasource#">
> >
> > SELECT
> >   PC.CategoryID,
> >   C.CategoryName,
> >   PC.SubCatID,
> >   PC.ProductID,
> >   SC.SubCatName,
> >   P.ProductName,
> >   P.ShortDescription,
> >   P.LongDescription,
> >   P.Price,
> >   P.SmallImage,
> >   P.LargeImage,
> >   P.Status,
> >   P.Company,
> > p.proddoc
> > FROM ProductsCategories PC,Categories C,SubCategories SC,Products P
> > WHERE  C.CategoryID = PC.CategoryID
> > AND SC.SubCatID = PC.SubCatID
> > AND  P.ProductID = PC.ProductID
> > AND P.Status = 'Yes'
> > ORDER BY P.ProductName;
> > </cfquery>
> >
> > <cfquery name="getProductDetail" dbtype="query">
> > SELECT ProductID, ProductName, Price, LongDescription,
LargeImage,Company
> > FROM getCatalog
> > WHERE ProductID = '#URL.thisProduct#'
> > </cfquery>
> >
> > This works with all product codes I pass exept ones previously described
> > such as 123-567-78
> >
> >
> >
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:216133
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to