ERROR MSG:
Msg 515, Level 16, State 2, Server SQL\CIS, Procedure ssp_gas_CustomerCancellation_A, Line 161
Cannot insert the value NULL into column '', table ''; column does not allow nulls. INSERT fails.
The statement has been terminated.
Why didn't it actually tell me the Column and table name? i've never seen this before?
Anyone can help
Thanks
Marios
Oh I know this isn't the right forum but i couldn't find the right one to post in.
How is the procedure executed?
Not sure about why the error message is like that. Are there many fields in the table that do not allow nulls, I'd start checking those.
|||It is called from another Stored Procedure the Stored Procedure that it rasises the error in is about 600lines of code and there are serval places where it Inserts int Tables and Temp Tables. I've looked at the data passed and which fields they are passed in to but i don't see where this error happends. It has only happend in our Production Database i can not so far reproduce it in our development environment. I don't understand why it doesn't show me the column and table
Thanks
Marios
|||Do you explicity create your temporary tables or create/populate them through select into statments? Maybe that is why it doesn't show the table/column name (the fact that that it is a temporary table).
Nevermind, just tested that and it doesn't seem to be the case.
|||no i explicitly defne the tables for temp tables before using them and but they are declare
CREATE #TableName
(
)
|||The only other thing I can think of, and I realize it may be impractical due to the large amount of code within the stored procedure is to use try...catch statements.|||i can't because it's a SQL 2000 server
No comments:
Post a Comment