NHibernate Forge
The official new home for the NHibernate for .NET community

Comments: Mapping a view and Schema Export Workaround

Wiki Page Hierarchy

Pages

Page Details

First published by:
Gustavo
on 09-05-2008
Last revision by:
markweee
on 03-30-2011
3 people found this article useful.
Comments (12)
History (7)

Mapping a view and Schema Export Workaround

Sort by: Published Date | Most Recent | Most Useful
1 2 3 Next >
By: Jose Ramirez Posted on 09-16-2008 10:40

<p>+1 for the jira issue</p>

<p>DROP TABLE doesn't solve the problem at all because generally the view already exists and you willl get an error when schemmaexport intents to create the homonym table</p>

By: Gustavo Posted on 10-17-2008 14:02

if the view already exists you are unit testing an existing DB...that's not good. You start from a blank DB and create all the entities. If you start with a blank DB as it is needed for unit tests, then the view doesn't exist.

By: Gustavo Posted on 12-16-2008 16:29

hooray for the new feature :)

By: Tuna Toksoz Posted on 03-16-2009 17:25

Will Shaver has proposed a way to specify what not to export

nhjira.koah.net/.../NH-1274

By: Buthrakaur Posted on 04-09-2010 3:46

The SchemaAction.None is nice, but it looks like it does not work in case when a class has many-to-many mapping - the SchemaExport is trying to create the association table even though the owning class has SchemaAction.None set. I have problem with this when using same tables to map to two classes currently - SchemaExport is trying to create the association table twice which results in DB exception because the table already exists..

Powered by Community Server (Commercial Edition), by Telligent Systems