wow this post seems to go into more depth as this seems to be a contentious issue: http://zvolkov.com/blog/post/2009/10/28/NHibernate-parameter-sizes-controversy.aspx
given this, how do you handle varchar(max) fields now. should I specify ansistring as the type and length=(some really large number) ? thanks scott On Oct 5, 1:57 pm, srf <[email protected]> wrote: > Seehttp://ayende.com/Blog/archive/2006/12/30/NHibernateAndLargeTextField... > , this mentioned this preparedsql flag thats commented out now, and it > getting the same result of the sql getting cut off because of it. > > On Oct 5, 1:54 pm, srf <[email protected]> wrote: > > > > > I was trying to figure out why things working working anymore in > > nhibernate 3 and noticed that in nhibernate 2 the dbparameter.size > > would be set to what the dbparameter.value's length was as long as the > > dbparameter.size was set to 0. Now in nhibernate 3, the > > dbparameter.size is getting set because line 164 in SqlClientDriver.cs > > is commented out so its now by default setting the size to some fixed > > size rather than setting the size to what the parameter value size is. > > So I was wondering why that is commented out now. The problem I have > > is that I have varchar(max) values and the parameter size could be > > really large so the parameter size need to be set to what the length > > of the text inserted or sqlserver will just cut it off to whatever the > > parameter.size is. Is handling really large text like varchar(max) to > > be done differently? > > > thanks > > > scott- Hide quoted text - > > - Show quoted text -
