Should I store HTML as nvarchar(MAX) or ntext?

后端 未结 3 1065
太阳男子
太阳男子 2021-02-19 20:23

I don\'t know if there\'s a limit to the number of characters if I choose nvarchar(MAX), and I\'m not sure how many characters I would need anyways.

What\'s the standard

3条回答
  •  孤独总比滥情好
    2021-02-19 20:46

    The ntext type is deprecated, as are text and image. Microsoft recommends replacing them with nvarchar(max), varchar(max) and varbinary(max) respectively.

    Use nvarchar(max), therefore.

    Reference:

    • ntext, text, and image (Transact-SQL)

提交回复
热议问题