Friday, May 9, 2014

Extract value from string in groovy

def f = new File("strings.xml")
def m = (f.text =~ "myAttribute\">(.*)<.*")
println m[0][1]

Get all tables that have a certain field

select table_name from columns where table_schema = 'mydatabase' and column_name = 'looking_for_this_field';