title: mismatched input 'from' expecting <EOF> SQL
body: <p>I am running a process on Spark which uses SQL for the most part. In one of the workflows I am getting the following error:</p>
  <blockquote>
  <p>mismatched input 'from' expecting </p>
  </blockquote>
  <p>The code is</p>
  <pre><code> select a.ACCOUNT_IDENTIFIER,a.LAN_CD, a.BEST_CARD_NUMBER,  
   decision_id, 
   case when a.BEST_CARD_NUMBER = 1 then 'Y' else 'N' end as best_card_excl_flag 
   from (select a.ACCOUNT_IDENTIFIER,a.LAN_CD, a. decision_id row_number()
   over (partition by CUST_GRP_MBRP_ID 
      order by coalesce(BEST_CARD_RANK,999)) as BEST_CARD_NUMBER 
   from Accounts_Inclusions_Exclusions_Flagged a) a 
  </code></pre>
  <p>I cannot figure out what the error is for the life of me</p>
  <p>I've tried checking for comma errors or unexpected brackets but that doesn't seem to be the issue.</p>