[fluent-nhib] Re: When mapping a byte array, how do I specify the maximum size?

2009-03-25 Thread James Gregory
I've just committed a change that removes the restriction of what types you can specify a length on. You can now use the WithLengthOf method without receiving that exception. On Tue, Mar 24, 2009 at 1:45 PM, Karron Qiu wrote: > try this. > > .CustomTypeIs("BinaryBlob"); > > On Tue, Mar 24, 2009

[fluent-nhib] Re: When mapping a byte array, how do I specify the maximum size?

2009-03-24 Thread Karron Qiu
try this. .CustomTypeIs("BinaryBlob"); On Tue, Mar 24, 2009 at 7:20 AM, pangyan wrote: > > Hmm, I did try that. With the latest Fluent NHibernate build > (0.1.0.416), I get the following error: > > System.InvalidOperationException: Content is not a string > > It looks like WithLengthOf is only

[fluent-nhib] Re: When mapping a byte array, how do I specify the maximum size?

2009-03-23 Thread pangyan
Hmm, I did try that. With the latest Fluent NHibernate build (0.1.0.416), I get the following error: System.InvalidOperationException: Content is not a string It looks like WithLengthOf is only usable with strings, not byte arrays. On Mar 11, 3:06 pm, James Gregory wrote: > Use the WithLengthO

[fluent-nhib] Re: When mapping a byte array, how do I specify the maximum size?

2009-03-11 Thread James Gregory
Use the WithLengthOf method. On Wed, Mar 11, 2009 at 9:42 AM, pangyan wrote: > > I've got this class: > > class Account > { >public int Id { get; set; } >public string FullName { get; set; } >public byte[] Photo { get; set; } > } > > When mapping Photo, using Map(x => x.Photo), it wo