Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] Execute SQL after table creation.

On Dom 24 Oct 2010 01:14:05 Frank Schwarz escribió:
> How about this?:
> 
> 
> @Override
> public void customize(Session session) throws Exception {
> 	session.getEventManager().addListener(new SessionEventAdapter() {
> 		@Override
> 		public void postLogin(SessionEvent event) {
> 			java.sql.Connection connection =
> 					
((AbstractSession)event.getSession()).getAccessor().getConnection();
> 		}
> 	});
> }
> 
> There is however no indication of whether EL just (re-)created the database
> structure. You have to check that yourself.
Unfortuntely, this execute the querys just before the tables are created and 
what I need is to execute the querys after de tables are created.

Any other idea?
> 
> 
> -- Frank
> 
> Arcangel wrote:
> > Hello.
> > 
> > I want to execute some SQL sentences one time after the database is
> > created
> > with eclipselink. How can I do that?


Back to the top