SELECT *
FROM [SELECT A.*,KEY1 & (SELECT COUNT(*) FROM B105T WHERE A.KEY3>=KEY3 AND A.KEY1=KEY1) AS DF FROM B105T A ORDER BY 4 ]. AS [%$##@_Alias]
ORDER BY DF;
SELECT *
FROM [SELECT A.*,KEY1 & (SELECT COUNT(*) FROM B105T WHERE A.KEY3>=KEY3 AND A.KEY1=KEY1) AS DF FROM B105T A ORDER BY 4 ]. AS [%$##@_Alias]
ORDER BY DF;