Need Help with Oracle-TOAD Query

  • New to SQL and need help. Using Oracle-TOAD. Get an error: ORA-00933 command not properly ended. Thanks!

    select DISTINCT clm_id

    ,SUM(clm_pd_amt) AS c_p_a

    ,MAX(r_date) AS ran_date

    ,MIN(clm_stat) AS c_stat

    FROM i_mra.cbn

    WHERE clm_stat in (5,8)

    AND clm_type IN ('r', 'p')

    AND svc_date between '20190101' and '20191231'

    AND pd_date >= '20190101'

    AND pd_date <= '20200131'

    AND year = 2019

    GROUP BY clm_id, clm_pd_amt, r_date, clm_stat

  • This is a double post.  Did none of the answers in the previous thread help?

    The query is identical...

    Link:

    https://www.sqlservercentral.com/forums/topic/need-help-with-sql-code

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply