|
Hi,
my company's application is in the progress of supporting a second database alongside our current one. This means we will be supporting 2 different dialects, the old one, Postgres8 and the new one Oracle10g. My question is if it's possible to alter Hibernate's dialect depending on a server setting.
The problem I face is that we have to set our dialect in hibernate.cfg.xml for various reasons(our database schema builder depends on it among other things) and so, as far as I have understood it, this means that I cannot use the Configuration class because Hibernate will overwrite it. What I have also tried is using a server setting for use in JNDI in combination with Spring, however, I don't think it's possible to create a Dialect object with Spring.
I'm currently looking for another solution for this problem, does someone have any ideas?
|