views:

213

answers:

3

I have recently moved a database from Sql Server 2000 to Sql Server 2005. In the table designer, it insists on putting square brackets around a column named "Content" I don't see Content on the list of reserved words for Sql Server, so I don't understand why it is doing this. Is there a way I can prevent it?

+10  A: 

CONTENT is a keyword when defining an XML column with a schema.

See here.

Jeremy Smyth
all true tho they did forgot to add it to the list of reserved words on msdn :) anyway ... +1 nice link
Lil'Monkey
It is not in the list of keywords for sql server on MSDN
pthalacker
A: 

No, you can't prevent it. You can always add square brackets around a column name so it doesn't hurt anything.

David
A: 

The problem is that the field has the same name as the table. Sql Server 2000 did not seem to care about this potential ambiguity, but Sql Server 2005 does. When I add a field named Content to a table that is not named Content, the square brackets do not appear.

pamela

pthalacker