ColdFusion · Database exception
What does Invalid Data For CFSQLTYPE CF_SQL_INTEGER mean in ColdFusion?
cfqueryparam rejects a value before it ever reaches the database because it can't be coerced to the declared cfsqltype — most often an empty string reaching a param typed CF_SQL_INTEGER, but also a value that's quietly treated as a different type (money vs. integer) elsewhere in the app. This is ColdFusion's own type check firing, not a database-side SQL error.
cfqueryparam rejects a value before it ever reaches the database because it can't be coerced to the declared cfsqltype — most often an empty string reaching a param typed CF_SQL_INTEGER, but also a value that's quietly treated as a different type (money vs. integer) elsewhere in the app. This is ColdFusion's own type check firing, not a database-side SQL error.
Add null="#not len(trim(variable))#" to the cfqueryparam so empty values map to a real NULL instead of an invalid integer, or validate with isValid("integer", value) before the query runs.