I am wanting to create a public saved query that shows the below information, but that also determines the logged in user's defsite, so that the user only sees work orders pertaining to their site.
This works correctly: (woclass in ('WORKORDER','ACTIVITY')
and historyflag = 0
and istask = 0
and worktype in ('MPM')
and fnlconstraint >= timestamp(current date - (day(current date) - 1) days)
and fnlconstraint < timestamp(current date - (day(current date) - 1) days + 1 month)
)
and status != 'COMP'
but when I add the siteid part below, it does resolve the correct userid but it seems to not be able to find defsite or return it as siteid, and it says 0 results.
(woclass in ('WORKORDER','ACTIVITY')
and historyflag = 0
and istask = 0
and worktype in ('MPM')
and fnlconstraint >= timestamp(current date - (day(current date) - 1) days)
and fnlconstraint < timestamp(current date - (day(current date) - 1) days + 1 month)
and siteid = (select defsite
from maxuser
where userid = :user))
and status != 'COMP'
Is there a suggested way to pull the logged in user's default site?
Thank you
#Administration
#Customizations
#EndUser
#EverythingMaximo
#Reporting
#Scheduling
#WorkManagement
------------------------------
Danny Richardson
Maximo Administrator Manager
Technimark LLC
------------------------------