In my ASP.NET 4.0 / VB web form I'm getting this error when I try to submit the form:
Cannot insert the value NULL into column 'CandidateID', table 'OJT.dbo.Pipeline'; column does not allow nulls
Here is my INSERT statement:
Dim sql As String = "INSERT INTO Pipeline (Office, EmployerID, EmployerName, NewEmployer, Position, Funding) VALUES (@Office, @EmployerID, @EmployerName, @NewEmployer, @Position, @Funding); SELECT SCOPE_IDENTITY();"
There is NO "CandidateID" anywhere in the sql statement. Nowhere. Not at all. The word "Candidate" does not exist in my SQL anywhere.
I've edited and saved the page multiple times.
I've done a "REBUILD" in Visual Studio 2012
I loaded the page on a DIFFERENT COMPUTER in case it was cached in my browser.
I did Ctrl-F word search for the word "CandidateID" in my code. It's not there. Anywhere. (other than some commented out lines.)
Yes, it was in the insert statement at one time, but it's not now. I removed it. See INSERT statement above. What is going on here?