Hi,
Have solved the problem I had to go to the database and delete the tables.
And run the SchemaUpdate worked fine. I know this is the wrong way. But if
nothing helps you have to give your 100%
regards
prasad chandrasekaran


----- Original Message -----
From: "Prasad Iyer" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, August 20, 2003 6:30 PM
Subject: Re: [Hibernate] Updating the database schema


> Hi,
>
> Following is the code which I am using to update the schema. But this
isn't
> working for me.
>
> Can you help me. Thanks for the earlier response.
>
> try{
>
> HibernateFileConfiguration hfcfg = new HibernateFileConfiguration();
>
> ListIterator iterator = hfcfg.getFilelist().listIterator();
>
> while(iterator.hasNext())
>
> {
>
> String filename = (String)iterator.next();
>
> System.out.println("Database configured for: " + filename);
>
> try{
>
> cfg.addFile(filename);
>
> }
>
> catch(Exception e){}
>
>
> }
>
> }catch(Exception ex){
>
> ex.printStackTrace();
>
> }
>
> try{
>
> new SchemaUpdate(cfg).execute(true);
>
>
> sessions=cfg.buildSessionFactory();
>
>
> }catch(Exception ex){
>
> ex.printStackTrace();
>
> }
>
>
>
>
>
>
>
> ----- Original Message -----
> From: "Oliver Wehrens" <[EMAIL PROTECTED]>
> To: "Prasad Iyer" <[EMAIL PROTECTED]>
> Sent: Wednesday, August 20, 2003 5:51 PM
> Subject: Re: [Hibernate] Updating the database schema
>
>
> > There is an ant task, as well as commandline and an option from within
> > your
> > code. net.sf.hibernate.tool.hbm2ddl.SchemaUpdate, but this relies on
> > the jdbc driver metadata to work.
> >
> > Btw. does anybody know which jdbc drivers are supply enough metadata
> > to make this work?
> >
> > Oliver
> >
> > On Wednesday, August 20, 2003, at 02:06 PM, Prasad Iyer wrote:
> >
> > > Hi,
> > > I got this bunch of tables created for the application with mapping
and
> > > everything.
> > > I am in grave problem I need to add few columns to few tables with the
> > > relationship without disturbing the other table
> > > Does anybody knows how do I do that.
> > > An early reply would be highly appreciated.
> > > regards
> > > prasad chandrasekaran
> > >
> > >
> > >
> > > -------------------------------------------------------
> > > This SF.net email is sponsored by Dice.com.
> > > Did you know that Dice has over 25,000 tech jobs available today? From
> > > careers in IT to Engineering to Tech Sales, Dice has tech jobs from
the
> > > best hiring companies. http://www.dice.com/index.epl?rel_code=104
> > > _______________________________________________
> > > hibernate-devel mailing list
> > > [EMAIL PROTECTED]
> > > https://lists.sourceforge.net/lists/listinfo/hibernate-devel
> > >
> >
>
>
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by Dice.com.
> Did you know that Dice has over 25,000 tech jobs available today? From
> careers in IT to Engineering to Tech Sales, Dice has tech jobs from the
> best hiring companies. http://www.dice.com/index.epl?rel_code=104
> _______________________________________________
> hibernate-devel mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/hibernate-devel



-------------------------------------------------------
This SF.net email is sponsored by Dice.com.
Did you know that Dice has over 25,000 tech jobs available today? From
careers in IT to Engineering to Tech Sales, Dice has tech jobs from the
best hiring companies. http://www.dice.com/index.epl?rel_code=104
_______________________________________________
hibernate-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/hibernate-devel

Reply via email to