Skip to content

Instantly share code, notes, and snippets.

@sergiomichels
Created October 15, 2012 19:48
Show Gist options
  • Save sergiomichels/3894841 to your computer and use it in GitHub Desktop.
Save sergiomichels/3894841 to your computer and use it in GitHub Desktop.
Groovy Sql & ORA-00903 - Solution
def sql = new Sql(dataSource)
def tables =["myTable1", "myTable2"]
tables.each {tab ->
sql.execute("truncate table ${tab}".toString()) //works!
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment