Package org.hibernate.cfg

Examples of org.hibernate.cfg.Configuration.generateDropSchemaScript()


            String[] scriptCreateDdlArray = cfg.generateSchemaCreationScript(dialect);
            List<String> scriptCreateDdlList = Arrays.asList(scriptCreateDdlArray);
            File scriptCreateFile = new File(targetDir, dbName + "-create.sql");
            FileUtils.writeLines(scriptCreateFile, "UTF-8", scriptCreateDdlList, lineEnding);

            String[] scriptDropDdlArray = cfg.generateDropSchemaScript(dialect);
            List<String> scriptDropDdlList = Arrays.asList(scriptDropDdlArray);
            File scriptDropFile = new File(targetDir, dbName + "-drop.sql");
            FileUtils.writeLines(scriptDropFile, "UTF-8", scriptDropDdlList, lineEnding);
        }
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.