really parsing SQL to generate controller methods