I would like to retrieve at runtime the values for the ‘dialect’ and ‘connection.driver_class’ properties specified in the configuration file.
Do you know how to do that?
Many thanks, Nicola
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
When you build the Configuration object and load the XML and eventually build the SessionFactory, hang on to the Configuration object reference you have.
You can use the Properties object of the Configuration reference you have, or you can do something like Dialect.GetDialect(_configuration.Properties).