I'm doing an org.hibernate.tool.hbm2dll.SchemaExportTask
as part of my compile/build script (it is ant with hibernate4 plugin, if it is important).
Everything works wonderfully, except one:
It destroys all data!
What I want, is realistically a simple database dump, an equivalent of "pg_dump --all
" or like. It doesn't matter, if it is based on the xml configuration, or on the current database.
I don't want any modification on the real db, and particularly don' want any actually executed drop/create operations.
Is it possible anyhow in the sphere of the hibernate tools jars?
Ok, I solved this. Not the hibernate tools did the db-destroy, but hibernate at initialization. Setting hibernate.hbm2dll.auto
to update
fixed everything.