steve wrote:
Sure, include a file named import.sql at the root of your classpath. SchemaExport will pick up this file and "import" its contents after it has exported the schema.
The format of this file is a new-line-delimited series of SQL commands...
That is to say , if i place import.sql at the root of my classpth with .hbm.xml files together , Hibernate will automatically create table and dump predata into it??
I have tested your opinion , but didn't get data in table.
Should i do something else in my java files?
I use Ant to compile my project , and at the end of compiling , I make Ant to find the .hbm.xml files in project to create tables .
After creating tables in compiling process , i want to dump data into the tables next. That means i want to insert "dumping data" into the compiling process.
I am using Hibernate 2.1.8.