Posting with Limited Users?
Some questions about posting with limited users
NAV Limited User (licence type)
“If i use a limited user to write in Item Journal Line (T83) and then this same user posts this line, would this work? (assuming that codeunit 22 -Item Journal post line– will write in more than 3 extra tables).
If i use a limited user, do I have to specify somewhere which 3 tables he/she can write on, or this limitation is only valid in each different transaction he/she may perform?”
“People wants to configure what three additional application tables these limited users canuse. Base on the standard NAV, this is not possible. These users get write access to a maximum of three application tables in the object range 0 – 99,999,999 other than the General Ledger Entry table. But system will count the first three used application tables beside the default tables. This is counted by the session. That means, users can use different three application tables in different sessions.”
However you can limit it by setting up additional user permissions to shorten the list of tables to access.”
Nice questions… BUT…
#0 – DOGMA; Light User is NOT For Posting….. buy a FULL USER to Post !!!
#1 – WORKAROUND: Use Web Services to Post with a FULL USER (WS Service)
#2 – WORKAROUND: Use NAV NAS Service to Post with a FULL USER
#3 – WORKAROUND: Use Limited Users to write on Temporary Tables (others than available tables and selected tables on Security SETS)
Take a look to Totovic Post to configure Limited Users https://totovic.com/2016/03/02/how-to-configure-limited-users-in-nav/
#4 – WORKAROUND: Use an external NAV Addon or Application with limited usersother types of license: ex: MOBILE NAV etc,
Limited User (License Type), User Card
Ø Example for Limited User PERMISSON SET
READ: example: READ for ALL Tables
WRITE: example: WRITE only on my tables (5 tables defined on this SET -3 standard + 2 of addon)
NAV 2017 Limited Users Pre-Assigned Tables
Nice question on Forum by Tina Menezes about this topic.
Best PracticeWorkaround for question
“Writing the transactions of a Limited User to a temporary table then having a Full User (or a system process) post those transactions to table 17 is an example of indirect write access to table 17, which is not permitted.”
“Best way would be only write to item journal from external app with limited user without posting the lines. Create a Job queue entry which is run by a full User and posts periodically these Job journal lines.”
SAMPLES: “HOW-TO POST” SCENARIOS
You can use limited user to insert data on item journal, after you can post in 3 ways:
1- Post with Jobqueue using a Full User
Example: create and schedule a job that runs a Posting Codeunit (with one by one posting routine if you don0t want to block all posting when an error is detected).
2- Post using Exposed Web Service page called by NAV using Vjeko C/AL WebService Wrapper tool.
It’s my best method because is NAV on NAV technology; in this case I call a page exposed as web services that onOpen trigger launch directly a Posting Codeunit.
LIMITED USERS POSTING WITH VJEKO CODEUNIT – SCHEMA
o Sample page exposed as Web Services http://navsrv:7048/SERVICE/WS/COMPANY/Page/WSPostOutput
WITH WebService DO BEGIN
IF READMULTIPLE THEN
MESSAGE(‘Customer %1 %2 has balance of %3’,GETVALUE(‘No’),GETVALUE(‘Name’),GETVALUE(‘Balance_LCY’));
UNTIL NEXT = 0;
Actually is not possible to call Codeunits (only Pages), I think that is possible to call also codeunit.
You can donwload from here: https://mibuso.com/downloads/generic-web-services-client-v2-for-microsoft-dynamics-nav
VJEKO CODEUNIT (WRAPPER)
WEB SERVICES (EXPOSED PAGE)
Ø Call Web Service Wrapper codeunit
3- Use external app (c#, Visual .NET) to post (external technology)
Many links about these methodologies, nice but outside of NAV.
NICE TUTORIALS and POSTS
Consuming Web Service from inside NAV
“TUTORIAL”: Basic Tutorial of using NAV WebServices (Customer WebService)
Have a nice posting !