Forum Moderators: open
Could someone help me with this error
Microsoft OLE DB Provider for SQL Server error '80040e2f'
Cannot insert the value NULL into column 'FILE_ID', table 'asrhem_portal.dbo.FILES'; column does not allow nulls. INSERT fails.
/tos/admin/inc_submit.asp, line 190
If I take a look at line 190 I get this code:
If (Not MM_abortEdit) Then If (MM_editRedirectUrl <> "") Then
' execute the insert
Set MM_editCmd = Server.CreateObject("ADODB.Command")
MM_editCmd.ActiveConnection = MM_editConnection
MM_editCmd.CommandText = MM_editQuery
MM_editCmd.Execute
MM_editCmd.ActiveConnection.Close
Response.Redirect(MM_editRedirectUrl)
End If
End If
I hope someone can help me out!
Cannot insert the value NULL into column 'FILE_ID', table 'asrhem_portal.dbo.FILES'; column does not allow nulls. INSERT fails.
The FILE_ID column is set in the database not to accept nulls. Check it out and change it if it needs to allow nulls. Or if it is an identification column then maybe you need to set it to "Identity", so it automatically adds a value.