Hi
Can one help me to convert following SQL to SWQL
SELECT
*
FROM (SELECT
SUM(CASE
WHEN NodesCustomProperties.ATM_Branches = 'ATM Branches' THEN 1
ELSE 0
END) AS Total_ATM_BRanches
,SUM(CASE
WHEN NodesCustomProperties.BRANCH_TYPE = 'NON-ATM' THEN 1
ELSE 0
END) AS Total_NON_ATM_BRanches
,SUM(CASE
WHEN NodesCustomProperties.BRANCH_TYPE = 'NON-ATM' OR
NodesCustomProperties.ATM_Branches = 'ATM Branches' THEN 1
ELSE 0
END) AS Total_Branches
,NodesCustomProperties.City
FROM dbo.NodesCustomProperties
GROUP BY NodesCustomProperties.City) datata
WHERE datata.Total_ATM_BRanches <> 0
AND datata.Total_NON_ATM_BRanches <> 0
ORDER BY datata.City
Result of SQL query:
