April 3, 2006 at 6:25 am
I was attempting to add an article to a publication and raised the following error:
Msg 21395, Level 16, State 1, Server PROD, Procedure sp_MSarticlecol, Line 25
This column cannot be included in a transactional publication because the column ID is greater than 255.
Msg 14021, Level 16, State 1, Server PROD, Procedure sp_articlecolumn, Line 427
The column was not added correctly to the article.
I checked Syscolumns and sure enough the greatest colid value is 256, but there are only 230 rows on the table and 230 columns on that table. Does anyone know of an easy way to correct this? I see that colid is not an identity value but I am way nervous about updating that data. Also if anyone can offer any insight as to why the colid value got out of whack that'd be enlightening as well. Thanks
April 6, 2006 at 8:00 am
This was removed by the editor as SPAM
May 10, 2006 at 11:57 am
Here is how colid values get fragmented.
When you delete a column from a table, the corresponding record is deleted from syscolumns. When you later add a column to the same table, a new record is added to syscolumns with the new colid value (for some reason, the old one is not reused).
As far as how to solve it, I am still looking for a solution.
BR,
VG
May 10, 2006 at 12:59 pm
VG, thanks for the reply. Yes after some further research I discovered that we have dropped and receated a column on that table repeatedly through a series of code updates. The column in question was a computed column from a UDF. That UDF is dropped and recreated along with several views referring to the table. The only method we have found to deal with this is to copy all the data out, drop the objects tied to it, and then drop the table and recreate everything.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply