-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: How to dynamically create table using nhibernate
PostPosted: Fri Feb 09, 2007 5:53 am 
Newbie

Joined: Fri Feb 09, 2007 5:44 am
Posts: 1
hi,

I am new with nhibernate.
Can anyone show me or point me to a reference site on how to use nHibernate to create a new table dynamically in my ASP.NET 2.0 code?

Thanks.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 09, 2007 7:15 am 
Contributor
Contributor

Joined: Sat Sep 24, 2005 11:25 am
Posts: 198
You can't.
NHibernate will not create a table for you.

What IS possible is to generate the entire schema of the database for you.
Take into account that this is done via DROP TABLE / CREATE TABLE, so it will NOT preserve the data.

You can use this functionality by using:

Configuration cfg = new Configuration();
new SchemaExport(cfg).Execute(true,true);


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.