Modify write SQL checking to use a regular expression for more flexible matching, eg. "   update foo" as well as "UPDATE foo".