Real User Monitoring
User session monitoring, key user actions - everything RUM.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

USQL - User sessions query - Filter based on computed value

kmahali
Visitor
SELECT
  usersession.startTime,
  userevent.startTime ,
  usersession.userSessionId,
  usersession.stringProperties.user_loginid,
  (userevent.startTime - usersession.startTime )/60000 AS error_occurrence
FROM userevent
WHERE page = '/error_page'
AND error_occurrence > 5

The above query would not work; it shows error 'Unknown field: error_occurrence'. Is there any other option to achieve this?

3 REPLIES 3

Khejazi
Participant

Hi,

 

Unfortunately, you can't use Alias in Where clause, you can use only fields.

Thanks Khejazi, for your reply.

`AND (userevent.startTime - usersession.startTime )/60000 > 5`
Even with the fields arithmetic is not allowed. Is there any workaround for this?

Khejazi
Participant

It will be the same since you are using an expression which is not originally a field in the table

Featured Posts