Beginner |
![Beginner Beginner](./images/ranks/beginner.gif) |
Joined: Tue Aug 17, 2004 5:06 am Posts: 46
|
Hibernate version: 2.1
Name and version of the database you are using: MS SQL Server with a bizarre Navision Schema that prohibits null-values in columns
I am facing a rather stupid problem when using Hibernate on a MS SQL Server database that hosts a Navision database schema. Besides other nice ideas Navision does not allow a database column to be null, so we have to invent null-values.
Normally we use 0 for null if it's a numeric field. Unfortunately one of these numeric fields is part of a foreign key field, so Hibernate thinks that there's an object associated (the key is technically not null) and fails once the proxy gets initialized (because the key points to no record).
My question is: Is there any means of telling a relationship which key values are to be interpreted as null ?
|
|