title: select distinct but return other columns using ORACLE
body: <p>I am trying to to do a select distinct on the 'url' field while pulling in the data for a few other fields.  I tried the below but it gives me some error message 'missing expression'.  I'm using ORACLE.  Can anyone help me</p>
  
  <pre><code>SELECT distinct on url,
                  is_aw_grp_id,
                  is_aw_page_id,
                  eppcm_contentid
    FROM ps_z_google_srch
   WHERE     url &lt;&gt; ' '
         AND EPPCM_CONT_TYPE = 'H'
         AND TO_CHAR (dttm_imported, 'dd-MON-yyyy HH:MM:SS') &gt;=
                (SELECT TO_CHAR (LASTCHANGEDTTM, 'dd-MON-yyyy HH:MM:SS')
                   FROM PS_Z_CONT_LAST_CHG
                  WHERE RECNAME = 'Z_GOOGLE_SRCH')
  </code></pre>