So there I was... attempting to figure out the best way to to a like clause in a query statement using the cfqueryparam tag.
I had it coded like this:
like <cfparam cfsqltype="cf_sql_varchar" value="#arguments.search_criteria#">
Well that didn't work. So I did some googling. After a little bit of searching, I finally found out how it should be coded.
like <cfparam cfsqltype="cf_sql_varchar" value="%#arguments.search_criteria#%">
After laughing at how simple that was... I used it. Worked like a charm.
No comments:
Post a Comment