cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

USQL useraction filter not working as expected

fstekelenburg
DynaMight Pro
DynaMight Pro

I am trying to create a table of selected key user actions with a filter based on their name. However, whatever I try to use as filter on useraction.name, the result set contains more results than the desired selection. No matter if I use useraction.name IN, IS, =, STARTWITH or LIKE.

 

example:

 

SELECT useraction.name, AVG(useraction.visuallyCompleteTime) AS VCT FROM usersession WHERE useraction.application='APPNAME1' AND browserType='Desktop Browser'  AND useraction.targetUrl STARTSWITH "https://my.site" AND useraction.name IN ("my - some page") GROUP BY useraction.name ORDER BY useraction.name DESC

 


Other selections that appear not to have a result are  useraction.keyUserAction IS true and useraction.internalKeyUserActionId STARTSWITH "APPL"


Example of query result, with expected results in green box:

fstekelenburg_0-1616628750847.png

 

 

Kind regards, Frans Stekelenburg                 Certified Dynatrace Associate | measure.works, Dynatrace Partner
1 REPLY 1

fstekelenburg
DynaMight Pro
DynaMight Pro

Thanks to Collin of support I was pointed out that I needed to reverse my query, using useraction not usersession, and pull the session variables from usersession.<var>, thus:


SELECT useraction.name, AVG(usersession.visuallyCompleteTime) AS VCT FROM useraction WHERE useraction.application='APPNAME1' AND usersession.browserType='Desktop Browser'  AND usersession.targetUrl STARTSWITH "https://my.site" AND useraction.name IN ("my - some page") GROUP BY useraction.name ORDER BY useraction.name DESC




Kind regards, Frans Stekelenburg                 Certified Dynatrace Associate | measure.works, Dynatrace Partner

Featured Posts