top 1 cas dans l'instruction select sur TSQL

Je vais avoir des problème sur cette requête. Comment puis-je résoudre ce problème:

select (select case top 1 STATUS 
       when 'Inprocess' then 'Processing' 
       when 'Inworkbin' then 'Waiting In Draft' 
       end 
    from ICS_EMAIL_CONNECTIONS_TRX A    
    where A.SESSIONID = B.SESSIONID 
    and STATUS <> 'Completed'
    order by A.CREATE_DATE desc) as LAST_STATUS 

J'obtiens cette erreur:

Syntaxe incorrecte près du mot clé "top".

Des suggestions?

InformationsquelleAutor cihata87 | 2013-05-02