|
From: Michael T. (JIRA) <nh...@gm...> - 2011-05-25 17:29:54
|
[ http://216.121.112.228/browse/NH-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=21194#action_21194 ]
Michael Teper commented on NH-2739:
-----------------------------------
Nullability might be a problem with SchemaAction = SchemaAutoAction.Recreate. When I blew away the database and started from scratch, the image column was created correctly as not null.
Would still like to know if there is anything I can do to have NH generate varbinary(max) in place of image.
Thanks!
> Can't get ByCode mapping to produce not nullable varbinary(max)
> ---------------------------------------------------------------
>
> Key: NH-2739
> URL: http://216.121.112.228/browse/NH-2739
> Project: NHibernate
> Issue Type: Bug
> Components: Mapping by-code
> Affects Versions: 3.2.0Beta1
> Reporter: Michael Teper
> Priority: Major
>
> Trying to map the following class:
> public class MyData
> {
> public byte[] Data { get; set; }
> }
> to 'varbinary(max) (not null)' field in SQL Server 2008.
> mapper.Class<MyData>(map =>
> {
> map.Property(x => x.Data, m => m.Length(int.MaxValue));
> map.Property(x => x.Data, m => m.NotNullable(true));
> });
> produces 'image(null)'
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
|