change ILIKE into LOWER() for compatibility with non-Pg and Pg before 7.1