Problem with update record form
I have an update record form that uses a <cfquery> function and has (among other fields) an optional file input field and two separate fields to specify the file name and file type. I don't get any errors when I submit the form, but it does not update the record and does not redirect to the page specified in the <cflocation> function. Instead, it simply reloads the update record page with all values removed. The cfquery function is copied below. Any ideas what I'm missing? I'm relatively new to cf and sql, but in comparing it to other update record forms I have for other tables, I can't find a problem.
<cfif IsDefined("FORM.MM_UpdateRecord") AND FORM.MM_UpdateRecord EQ "content_edit">
<cfquery datasource="everettweb">UPDATE Content
SET Page_URL=<cfif IsDefined("FORM.Page_URL") AND #FORM.Page_URL# NEQ "">
#FORM.Page_URL#
<cfelse>
''
</cfif>
, Page_Category=<cfif IsDefined("FORM.Page_Category") AND #FORM.Page_Category# NEQ "">
#FORM.Page_Category#
<cfelse>
''
</cfif>
, Content_Description=<cfif IsDefined("FORM.Content_Description") AND #FORM.Content_Description# NEQ "">
#FORM.Content_Description#
<cfelse>
''
</cfif>
, Content_Heading=<cfif IsDefined("FORM.Content_Heading") AND #FORM.Content_Heading# NEQ "">
#FORM.Content_Heading#
<cfelse>
''
</cfif>
, Content=<cfif IsDefined("FORM.Content") AND #FORM.Content# NEQ "">
#FORM.Content#
<cfelse>
''
</cfif>
, Image_URL=<cfif IsDefined("FORM.Filename") AND #FORM.Filename# NEQ "">
/images/#FORM.Filename#.#FORM.File_type#
<cfelse>
''
</cfif>
WHERE ID=#FORM.ID#
</cfquery>
<cflocation url="#FORM.Page_URL#">
</cfif>
Thanks for any help you can provide!
Jeremy
