Another Reason to use CFQUERYPARAM

March 08, 2004

A question posed on the BlueDragon Interest list today by Jeff Houser revealed another advantage to using CFQUERYPARAM in your queries.

Since CFML accepts several valid values for boolean values (0/1, yes/no, true/false). When it comes time to use one of these values in a database query you typically want to use the 0/1, but if the variable resolves to a Yes/No value your database server will throw an exception. Guy Rish suggested that if you use CFQUERYPARAM you can force the proper datatype using the cfsqltype attribute.

1 person found this page useful, what do you think?

Post a Comment


Spell Checker by Foundeo

Recent Entries


did you hack my cf?