Title:
Bug 81727:<!--- the following query resides in a CFC which is called via cfajaxproxy from javascript functions ---><!--- using SQL Server 2000 ---><!--- during development this code worked fine, but did not wor
| View in TrackerStatus/Resolution/Reason: Closed/Withdrawn/
Reporter/Name(from Bugbase): Matthew Currier / Matthew Currier (fingerskier)
Created: 01/22/2010
Versions: 9.0
Failure Type: Unspecified
Found In Build/Fixed In Build: 0000 /
Priority/Frequency: Normal / Unknown
Locale/System: English / Win All
Vote Count: 0
Problem:
<!--- the following query resides in a CFC which is called via cfajaxproxy from javascript functions ---><!--- using SQL Server 2000 ---><!--- during development this code worked fine, but did not work at all in some cases (e.g. when I was testing an issue reported by a user)I am looping over a list and running this query each timeeach iteration of the loop generated the exact same query (the data from the final iteration of the loop)however, nothing was changed in the database, I tried everything but restarting the server---><cfquery datasource="#Application.DS#" result="Q">UPDATEelementsSETX=<cfqueryparam cfsqltype="CF_SQL_VARCHAR" value="#listGetAt(arguments.X, I)#">,Y=<cfqueryparam cfsqltype="CF_SQL_INTEGER" value="#thisY#">,Z=<cfqueryparam cfsqltype="CF_SQL_DECIMAL" value="#thisZ#">WHEREID = <cfqueryparam cfsqltype="CF_SQL_INTEGER" value="#thisID#"></cfquery><!--- I tried this as an alternative to no avail...after creating lists containing my data ---><cfquery datasource="#application.DS#" result="Q">UPDATEelementsSETX = <cfqueryparam cfsqltype="cf_sql_varchar" maxlength="100" list="true" value="#finalXes#">,Y = <cfqueryparam cfsqltype="cf_sql_integer" list="true" value="#finalYs#">,Z = <cfqueryparam cfsqltype="cf_sql_decimal" list="true" scale="2" value="#finalZ#">WHEREID = <cfqueryparam cfsqltype="cf_sql_integer" list="true" value="#finalIDs#"></cfquery><!--- this query (without cfqueryparam) works beautifully, though it requires additional validation of data... ---><cfquery datasource="#Application.DS#" result="Q">UPDATEelementsSETX='#listGetAt(arguments.X, I)#',Y=#thisY#,Z=#thisZ#WHEREID = #thisID#</cfquery>
Method:
Result:
Unexpected results when performing a cfquery within a loop...
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 3040813
External Customer Info:
External Company:
External Customer Name: Matthew Currier
External Customer Email: 017D6A44475B604399201587
External Test Config: 01/22/2010
Attachments:
Comments: