Mapping Hibernate to nhibernate

17 views
Skip to first unread message

Samuel Alkimim

unread,
Feb 11, 2020, 3:23:19 PM2/11/20
to Fluent NHibernate
Can anyone change the code bellow in Hibernate to nhibernate, i've been tried many things but i haven't success, can anyone help me please?

<property name="Document" type="BinaryBlob" >
      <column name="Document" sql-type="image"/>
</property>

Oskar Berggren

unread,
Feb 11, 2020, 4:03:55 PM2/11/20
to fluent-n...@googlegroups.com
What's wrong with it? The mapping XML for NHibernate should be the same I think.

Hmm... or do you actually mean to convert it into FluentNHibernate syntax?

Looks pretty straightforward to me:

    Map(p => p.Document).Column("Document").CustomSqlType("image");

What have you tried and what problems to you get?

Use .CustomType() also if you need to adjust how NHibernate handles it.


--
You received this message because you are subscribed to the Google Groups "Fluent NHibernate" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fluent-nhibern...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fluent-nhibernate/0ae2237e-0bc0-42e2-bb61-c9b5cd44adeb%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages