groovy - How can I execute SQL file which contains several other SQL files using gradle? -


how can execute sql file contains several other sql files using gradle?

i tried using following code:

gradle.class.classloader.addurl(new file('sql/ojdbc6.jar').touri().tourl())        def sql = groovy.sql.sql.newinstance(jdbcurl, db_prop_schema, db_prop_password,       'oracle.jdbc.driver.oracledriver')  string sqlfilepath = "testsql.sql" string sqlstring = new file(sqlfilepath).text  sql.execute(sqlstring)        sql.close() 


Comments

Popular posts from this blog

java - Run spring boot application error: Cannot instantiate interface org.springframework.context.ApplicationListener -

reactjs - React router and this.props.children - how to pass state to this.props.children -

Excel VBA "Microsoft Windows Common Controls 6.0 (SP6)" Location Changes -