cancel
Showing results for 
Search instead for 
Did you mean: 
Create Post
Level 12

SWQL Query working on Orion but not EOC

Can anyone point me in the right direction why this boiled down bit of SWQL code would work fine from one of the Orion instances, but fail when trying to run from EOC against all those same Orion instances?

select rt.Node.Caption, Min(DateTime) as First, Max(DateTime) as Last from Orion.ResponseTime rt

where rt.Availability<>100
and DateTime>ADDDATE('HOUR', -1, GETDATE())

Group By rt.Node.Caption

The error indicates "Subquery column with 'PropertyRef/T2.C4' not found".

Tags (3)
0 Kudos
1 Reply
Product Manager
Product Manager

mwb​ the federated SWIS can be a bit different in some cases.  Try this query - see if that helps.  

SELECT Caption, MIN(ResponseDateTime) AS First, MAX(ResponseDateTime) AS Last

FROM(

SELECT rt.Node.Caption as Caption, rt.DateTime as ResponseDateTime

FROM Orion.ResponseTime rt 

WHERE rt.Availability<>100 

AND DateTime >ADDDATE('HOUR', -1, GETDATE()) 

)

GROUP BY Caption 

0 Kudos