I'm trying to get my Unmanage Resource to sort by Unmanaged From. I've tried different things and it keeps erroring out. This is what I have now, without the attempt I made sorting by UnmanagedFrom. Can anyone take a look and see if they can assist?
SELECT
NodeName AS [Node Name],
'/Orion/images/StatusIcons/Small-' + StatusIcon AS [_IconFor_Node Name],
DetailsUrl AS [_LinkFor_Node Name], MAX(ToLocal(Nodes.UnmanageFrom)) AS [Unmanaged From], MAX(ToLocal(Nodes.UnmanageUntil)) AS [Unmanaged Until]
FROM Orion.Nodes
WHERE UNMANAGED = 1
GROUP BY NodeName, StatusIcon, DetailsUrl, Nodes.CustomProperties.Alert_Team, Nodes.CustomProperties.Business_Function
ORDER BY NodeName