I have a SQL Database that has some Table and in that table there's a Column.
I'm using NHibernate to do an update to a record, when I get this exception saying I'm violating some RULE on the column.
I do some research to find out there's a RULE associated with that column in the database, but I have no idea how to find this rule, see what it does, etc.
Does anyone know how to show the rules for a column? Or just all the rules in the database, anything to get me heading in the right direction.
** EDIT **
The exact error message is:
A column insert or update conflicts with a rule imposed by a previous CREATE RULE statement. The statement was terminated. The conflict occurred in database '[MYDB]', table '[MYTABLE]', column '[MYCOLUMN]'.
Do sp_help TableName
. It will return a number of resultsets, one of which (the 7th one) shows the contraints on the table.
You can also inspect the other resultsets for not nullable columns, identity columns, etc.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With