title: Problem with using regex_match in Redshift
body: <p>I am using following code for regular expression matching but getting this error:</p>
  <p>Error:</p>
  <blockquote>
  <p>Invalid operation: function regexp_matches(character varying, character varying) does not exist;</p>
  </blockquote>
  <p>Code:</p>
  <pre><code>WHEN REGEXP_MATCHes (tdahw.referrer, 'www.*/'::text) IS NOT NULL AND     REGEXP_MATCHes(tdahw.event_value, 'www.*/'::text) = REGEXP_MATCHes(tdahw.referrer, 'www.*/'::text) AND tdahw.rolling_count = 1 THEN 'Direct'::text
  WHEN REGEXP_MATCHes(tdahw.referrer, 'www.*/'::text) IS NOT NULL AND REGEXP_MATCHes(tdahw.event_value, 'www.*/'::text) &lt;&gt; REGEXP_MATCHes(tdahw.referrer, 'www.*/'::text) AND tdahw.rolling_count = 1 THEN 'Referrer'::text
  WHEN REGEXP_MATCHes(tdahw.referrer, 'www.*/'::text) IS NULL THEN 'Referrer'::text
  </code></pre>
  <p>How can it be rectified?</p>