PrimaryKeyIsAutoIncremented = FalsePrimaryKeyIsUpdateable = True
When I run my code, the error generated tells me:
Cannot insert explicit value for identity column in table 'MyTable' when IDENTITY_INSERT is set to OFF.
Dude...wudzupwiddat?Bill
Peter and Trent,
Thanks. I actually love the BOL. When this error came up I read the same entry that you mentioned, Peter. It does provide decent insight into what SQL Server is doing when manipulating the identity columns manually; however, I am not really doing that. I am inserting a record into a table that has multiple primary keys. None of the keys are identity columns. So, I think (I know...dangerous, at times) that this may be a setting on the BO somewhere. I will do a little more checking, now that I had a good night's sleep. I am sure something will pop out at me.
Bill
Thanks for all of your help!Bill
Btw, I really hope not. This is a really complex procedure and I have about 400 lines of code invested with several new business objects handling all of the heavy lifting. To relocate all of this logic (much of it is business logic and fits perfectly into the business object environment) to a stored procedure will be a nightmare. And, to explain this all to my manager will be even worse.
So, my hope is that SF can come through for me. Can you?Bill
Please check out this post: http://forum.strataframe.net/Topic17032-6-1.aspx?Highlight=BOM
I believe this may be related to your needs.
Related? Nope. Right on!!! That is exactly what I needed. I have made the necessary adjustments to my BOs and am now testing the procedure. So far, the results are good...very good. Man, am I glad that I did not have to rewrite any of this in TSQL.
Thanks!Bill
Hi Bill,
I am glad that was the answer. I was following this thread, but somehow got a bit lost with your situation, then with your last post, I saw the light