Have you tried surrounding the variable coming in with a Trim statement IE:

Where zipcode = <cfqueryparam type="cf_sql_varchar" value = "#Trim(valid
zipcode)#">

-----Original Message-----
From: Douglas Brown [mailto:mistobr...@gmail.com] 
Sent: Thursday, October 22, 2009 2:12 PM
To: cf-talk
Subject: OT database problem


I have a zipcode table that is driving me nuts...

If I open query analyzer and say

SELECT * FROM zip WHERE zipcode = 'valid zipcode' I get nothing back

but if I say

SELECT zipcode from zip I get all the zips back and the valid zipcode from
the first query is listed in there. Why cannot I not get anything with a
conditional statement in there?


Thanks 



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:327570
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to