/dbi\W+connect\(/i # grab every DBI connection call /(select)|(update)|(delete)/i # grab every thing that looks like SQL