Hibernate.properties – HP Integrity NonStop H-Series User Manual
Page 346

1.
Create the
hibernate.cfg.xml
file in the
EmployeeInfo/src
directory, as explained
in the
Creating the Hibernate Mapping File
section.
NOTE:
By default, XML files open in the XML Editor. The XML Editor has two views:
Design and Source view. Select the Source view.
2.
To modify the
hibernate.cfg.xml
file, complete the following steps:
•
Add reference for the Hibernate mapping file under
<session-factory>
tag.
•
Add reference for the Hibernate dialect file by including the following property tag
under
<session-factory>
tag.
org.hibernate.dialect.SqlmxDialect
•
Enable auto-creation of database tables using the Hibernate mapping file by including
the following property tag under the
<session-factory>
tag.
After modification, the
hibernate.cfg.xml
file appears as:
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
org.hibernate.dialect.SqlmxDialect
hibernate.properties
The
hibernate.properties
file contains the SQL/MX database details.
To create the
hibernate.properties
file, complete the following steps:
1.
On the Project Explorer frame, right-click EmployeeInfo and select New > File.
The New File dialog box appears.
2.
Change the parent folder to the
EmployeeInfo/src
directory. In the File name field, enter
hibernate.properties
. Click Finish.
The
hibernate.properties
file is created.
shows the New File dialog box.
346
Getting Started with Hibernate