Quantcast
Channel: THWACK: Message List
Viewing all articles
Browse latest Browse all 20625

SWQL query fails on website, but not in SWQL Studio

$
0
0

I have a pretty simple SWQL query that runs fine in SWQL studio, but for some reason it fails when I try to put it inside a "Custom SWQL Query" resource on the web interface (on an Application Details page).

 

Here's the query I'm using:


SELECT

'Notes' as PROPERTY, c.Notes as VALUE

FROM Orion.APM.ApplicationCustomProperties c

WHERE c.ApplicationId = ${ApplicationId}

UNION

(

SELECT

'WikiURL' as PROPERTY, c.Wiki as VALUE

FROM Orion.APM.ApplicationCustomProperties c

WHERE c.ApplicationId = ${ApplicationId}

)


*Note: I replace the "${ApplicationId}" variable with an actual ApplicationId when testing in SWQL studio, but it also fails on the web interface if I replace the "${ApplicationId}" variable with a static integer.


Individually, each SELECT statement works fine in the Custom SWQL Query resource, but not with the UNION statement. I think that syntax is correct, though?


Any tips/ideas?


Viewing all articles
Browse latest Browse all 20625

Trending Articles