<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Answers to: nvarchar(max)</title><link>https://answers.axonivy.com/questions/1988/nvarchar-max</link><description>&lt;p&gt;Hi All,&lt;/p&gt;
&lt;p&gt;What is the recommendation for having column like nvarchar(max) ?
what should I put in the Length value in the designer when creating Entities
nvarchar(max)  ? 2147483647 maybe ?&lt;/p&gt;
&lt;p&gt;Best Regards,
Yordan&lt;/p&gt;</description><atom:link href="https://answers.axonivy.com/questions/1988/nvarchar-max" rel="self"></atom:link><language>en</language><lastBuildDate>Tue, 30 Aug 2016 01:48:11 -0400</lastBuildDate><item><title>Answer by Genzer Hawker</title><link>https://answers.axonivy.com/questions/1988/nvarchar-max/1998</link><description>&lt;p&gt;Hi Stelt0&lt;/p&gt;
&lt;p&gt;If you put in the &lt;code&gt;Length&lt;/code&gt; with value &lt;code&gt;2147483646&lt;/code&gt;, it does give you the column &lt;code&gt;varchar(max)&lt;/code&gt;. If you really need to make it &lt;code&gt;nvarchar(max)&lt;/code&gt;, you may want to create a Java class (instead of a &lt;code&gt;Data Class&lt;/code&gt;) and then you can flexibly configure your &lt;code&gt;@Entity&lt;/code&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;@Entity
public class BlogPost extends CompositeObject {

    @Column(columnDefinition="nvarchar(max)")
    public String content;

}
&lt;/code&gt;&lt;/pre&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Genzer Hawker</dc:creator><pubDate>Tue, 30 Aug 2016 01:48:11 -0400</pubDate><guid>https://answers.axonivy.com/questions/1988/nvarchar-max/1998</guid></item><item><title>Comment by Reguel Wermelinger on Reguel Wermelinger's answer</title><link>https://answers.axonivy.com/questions/1988/nvarchar-max#1996</link><description>&lt;p&gt;yes: &lt;a href="https://de.wikipedia.org/wiki/42_(Antwort)"&gt;https://de.wikipedia.org/wiki/42_(Antwort)&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;but to really answer the question: you have to estimate the maximum length that will ever be used for that field. But that depends on your domain and can not be answered without knowledge about it. Choosing the maximum possible length will worsen your db performance.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Reguel Wermelinger</dc:creator><pubDate>Mon, 29 Aug 2016 12:19:23 -0400</pubDate><guid>https://answers.axonivy.com/questions/1988/nvarchar-max#1996</guid></item><item><title>Comment by Stelt0 on Reguel Wermelinger's answer</title><link>https://answers.axonivy.com/questions/1988/nvarchar-max#1995</link><description>&lt;p&gt;you are joking, right ?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stelt0</dc:creator><pubDate>Mon, 29 Aug 2016 11:49:08 -0400</pubDate><guid>https://answers.axonivy.com/questions/1988/nvarchar-max#1995</guid></item><item><title>Answer by Reguel Wermelinger</title><link>https://answers.axonivy.com/questions/1988/nvarchar-max/1994</link><description>&lt;p&gt;nvachar(42)              :-)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Reguel Wermelinger</dc:creator><pubDate>Mon, 29 Aug 2016 11:08:20 -0400</pubDate><guid>https://answers.axonivy.com/questions/1988/nvarchar-max/1994</guid></item></channel></rss>