TEXT and NTEXT fields

Topics: Developer Forum, Project Management Forum, User Forum
Oct 3, 2007 at 5:28 AM
In my database, I need to store large amount of html text (like blog posts, etc). I store these values in Sql Server's TEXT fields, because of the limit of 8000 chars.

How do I do to DbEntry manage TEXT and NTEXT fields? (and if possible, when "auto-create" the tables, these fields will be generated correctly?)
Oct 3, 2007 at 9:25 AM
You could map all text ntext char varchar just as "System.String" if you don't need DbEntry to create table and vilidate object for you.

Other wise, the attributes should be used for the field:
public string Name;  // nvarchar(10)
[MaxLength(10), StringColumn(IsUnicode = false)]
public string Name;  // varchar(10)
public string Name;  // ntext
[StringColumn(IsUnicode = false)]
public string Name;  // text

MySql and Firebird doesn't supported ntext or nvarchar, so in DbEntry, if use those database, it will mapped as text and varchar.