How To Get Login User Code in SAP B1 Query Manager
In SAP Business One, We can save Query we already created in Query Manager. We can use that Query for multiple purposes such as
- Custom Alerts,
- Custom Approvals and
- FMS (Formatted Search)
To get Login User Code in SAP Business One Query and to Enhance the Query We just need to add $[USER].
Hana: SELECT T0.”USER_CODE” FROM “OUSR” T0 WHERE T0.”USERID” = $[USER]
SQL: SELECT T0.USER_CODE FROM OUSR T0 WHERE T0.USERID = $[USER]