thanks, i just didnt know what to do with the single quotes:) ----- Original Message ----- From: "Marius Milosav" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Saturday, May 31, 2003 10:05 PM Subject: Re: quick query param question
> you can replace it with the following: > <cfqueryparam cfsqltype="cf_sql_integer" value="#stComp.accountOwnerID#"> > > <cfquery name="quser" datasource="hnr"> > SELECT userID, username, fName, lName, phone, email, city, state, zip > FROM user > WHERE username = <cfqueryparam cfsqltype="cf_sql_varchar" > value="#SESSION.Username#"> > </cfquery> > > Marius Milosav > www.scorpiosoft.com > It's not about technology, it's about people. > Virtual Company (VICO) Application Demo > www.scorpiosoft.com/vicodemo/login.cfm > > ----- Original Message ----- > From: "Dave Lyons" <[EMAIL PROTECTED]> > To: "CF-Talk" <[EMAIL PROTECTED]> > Sent: Saturday, May 31, 2003 10:00 PM > Subject: quick query param question > > > > what do u do with single quote when adding query param to a sql statement? > > > > say when i want to do it when im filtering by session.username > > do i add the single quotes to the query param or can i leave them out? > > > > > > <!--- Get user ---> > > <cfquery name="quser" datasource="hnr"> > > SELECT userID, username, fName, lName, phone, email, city, state, zip > > FROM user > > WHERE username = '#SESSION.Username#' > > </cfquery> > > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| 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 Get the mailserver that powers this list at http://www.coolfusion.com Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

