I am getting the following error sometimes. When the user load gets heavy I'll receive the following error. Would puting cftransaction around my update statements work?
ODBC Error Code = 40001 (Serialization failure)
DiagnosticsODBC Error Code = 40001 (Serialization failure Microsoft ODBC SQL Server Driver SQL Server Transaction (Process ID 53) was deadlocked on lock resources with another process and has been chosen as the deadlock victim.
The update statement I am using is really simple.
<cfquery name="update" datasource="#db#">
UPDATE sumDemo SET
Level = <cfqueryparam value="#form.level#" cfsqltype="cf_sql_char">,
hobbies = <cfqueryparam value="#form.hobbies#" cfsqltype="cf_sql_varchar">,
address = <cfqueryparam value="#form.address#" cfsqltype="cf_sql_varchar">,
phone = <cfqueryparam value="#form.phone#" cfsqltype="cf_sql_varchar">,
email = <cfqueryparam value="#form.email#" cfsqltype="cf_sql_varchar">,
colleges = <cfqueryparam value="#form.colleges#" cfsqltype="cf_sql_varchar">,
employ1 = <cfqueryparam value="#form.employ1#" cfsqltype="cf_sql_varchar">,
employ2 = <cfqueryparam value="#form.employ2#" cfsqltype="cf_sql_varchar">,
employ3 = <cfqueryparam value="#form.employ3#" cfsqltype="cf_sql_varchar">,
job1 = <cfqueryparam value="#form.job1#" cfsqltype="cf_sql_varchar">,
job2 = <cfqueryparam value="#form.job2#" cfsqltype="cf_sql_varchar">,
job3 = <cfqueryparam value="#form.job3#" cfsqltype="cf_sql_varchar">
where userid=<cfqueryparam value="#form.userid#" cfsqltype="cf_sql_varchar">
</cfquery>