Topic
1 reply Latest Post - ‏2013-02-14T19:40:10Z by SystemAdmin
npye
npye
2 Posts
ACCEPTED ANSWER

Pinned topic Max7.1.1.7 Need to restrict access to Labor in the Actual tab of WOTRACK

‏2013-02-14T15:30:38Z |
I need to restrict what is displayed when a user is in WOTRACK, Actual, Labor and clicks Select Labor. I want to restrict based on the current user &USERID& being in a common persongroup persongroupteam with the Labor that is to be displayed. I keep getting errors.
I am not good at SQL.
Here is my lastest attempt.
LABORID not in ((:&PERSONID& in PERSONGROUPTEAM.RESPPARTYGROUP) AND ( LABOR.PERSONID in PERSONGROUPTEAM.RESPPARTYGROUP))

Thanks,
Updated on 2013-02-14T19:40:10Z at 2013-02-14T19:40:10Z by SystemAdmin
  • SystemAdmin
    SystemAdmin
    5842 Posts
    ACCEPTED ANSWER

    Re: Max7.1.1.7 Need to restrict access to Labor in the Actual tab of WOTRACK

    ‏2013-02-14T19:40:10Z  in response to npye
    This might work:

    :LABORID IN (SELECT PERSONGROUPTEAM.RESPPARTY
    FROM PERSONGROUPTEAM
    WHERE PERSONGROUPTEAM.PERSONGROUP IN (SELECT PERSONGROUPTEAM.PERSONGROUP
    FROM PERSONGROUPTEAM
    WHERE PERSONGROUPTEAM.RESPPARTY = &USERID&))

    Brian