0

We're saving an object to NHibernate where the Id is typed Guid. Based on other things we've found we have this as a type char(36).

  • We create an object and save it via NHibernate. This works fine and we see 64599239BB0C1C48B44C36D9F9267830 in the column.
  • When we then try to load using a guid we don't get any results and NHibernate Profiler shows that the WHERE clause is looking for 0x64599239BB0C1C48B44C36D9F9267830 which isn't matching.

Obviously we're doing something wrong.. so any ideas what?

rebelliard
  • 9,592
  • 6
  • 47
  • 80
Shane Courtrille
  • 13,960
  • 22
  • 76
  • 113

1 Answers1

2

The data type on the database should be RAW, and of 16 length. This is what trying to recreate the database using NHibernate produces.

rebelliard
  • 9,592
  • 6
  • 47
  • 80