add TEXTPOS() used in pgsql < 7.0