Why Change log logs only my operation not of other users

andy76andy76 Member Posts: 616
Hello,

I have added a new table to log - Contact 5050: Insert (all fields), Modify (all fields), Delete ( All fields).

New records are created only if done by me, my user connected to the database but not the movements of other users...
Both I and the user have closed and reopened the company.

NAV 5.0

Why this? How to solve?

Thank you

Comments

  • krikikriki Member, Moderator Posts: 9,110
    Has the user the correct permissions?
    The user needs at least indirect permission to write in the log-table (and read the log-setup tables).

    BTW: closing and reopening the company probably is not enough (I am not sure). Try to close the DB and reopen it.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • andy76andy76 Member Posts: 616
    Users have indirect permission of read table 402.403.404,405 and indirect permission to write in table 405.

    If it was a problem of permission there would not be an error message?

    Thank you
  • David_SingletonDavid_Singleton Member Posts: 5,479
    andy76 wrote:
    Users have indirect permission of read table 402.403.404,405 and indirect permission to write in table 405.

    If it was a problem of permission there would not be an error message?

    Thank you

    No. When logging changes, the code first looks to see if the user has permission. If not it skips the code.

    Another issue cold be if you are connecting to Navision with a different license than the other user. For example if you are using a developer license (which you should never do) to connect to a live database.
    David Singleton
  • andy76andy76 Member Posts: 616
    We are a Microsoft Dynamics Partner and are using an internal use license partner / NFR having also full development permissions.
    All users have it because it is loaded in SQL.

    Thank you
  • GRIZZLYGRIZZLY Member Posts: 127
    andy76 wrote:
    We are a Microsoft Dynamics Partner and are using an internal use license partner
    If you are partner, then you could easily debug this case. Switch break on triggers and in Codeunit 1 put your attention on trigger OnGlobalModify.
    Sincerely yours, GRIZZLY
    Follow my blog at http://x-dynamics.blogspot.com
  • andy76andy76 Member Posts: 616
    My insert and modify are logged but the ones of simple user not... They cannot debug the code with their profile...
  • FSmeetsFSmeets Member Posts: 37
    Check with code coverage which objects are exactly hit when doing an action.
    After that you can check whether the user has the correct roles on this tables.

    Another way is to give the user temporarily access to the debugger, so you can log in with the account of the user to see what goes wrong.
  • GRIZZLYGRIZZLY Member Posts: 127
    andy76 wrote:
    They cannot debug the code with their profile...
    Why they cannot debug? Add the permission to Tools, Debugger (5310) to user and switch on Break on Triggers and Debugger.
    Sincerely yours, GRIZZLY
    Follow my blog at http://x-dynamics.blogspot.com
  • David_SingletonDavid_Singleton Member Posts: 5,479
    Go to their computer and run it logged in as you. if that works then it can only be permissions.

    Have you restarted both computers?
    David Singleton
  • andy76andy76 Member Posts: 616
    Having windows authentication access to NAV I should log in the user pc with my Windows username and then I will be SUPER so it would be as to be on my pc and think it logs.. so debugging unuseful.

    I can try but think that the problems are others or bug.

    Is it necessary to reboot the client as you suggest?

    Thank you
  • andy76andy76 Member Posts: 616
    I want to be sure that the steps to activate or add new tables to log are these:

    1) flag Change Log Setup form

    2) on same form press menu button : Setup -> Tables

    wait the loading of data that is dynamic - run time

    3) choose the table: in my case

    ID Name Log Insertion Log Modification Log Deletion
    5050 Contact All Fields All Fields All Fields

    leave the form and reopen NAV on my client and on the client of the user (others users must not logout and login)

    Is there something else?

    Thank you
  • David_SingletonDavid_Singleton Member Posts: 5,479
    Go to their computer and run it logged in as you. if that works then it can only be permissions.

    Have you restarted both computers?
    David Singleton
  • andy76andy76 Member Posts: 616
    I think to have solved without modifying the permission but deleting all records of table 405 -Change Log Entry and the single record of table 402 - Change Log Setup and then re inserting the flag in Change Log Setup form, and then logoff and login of both pc.
    I found these suggestions on other mibuso posts but don't understand why doing that solves...probably bugs because it is not logical...

    Thank you
  • David_SingletonDavid_Singleton Member Posts: 5,479
    Most likely it was logging off and back on the computers that fixed it. Not sure why you didn't want to just do that.

    Every time someone has told me they found a bug in Change log, it eventually was Always either License, permissions, or they forgot to log out and back into Navision.
    David Singleton
  • andy76andy76 Member Posts: 616
    I think that the real cause was that the user is using NAV in Terminal Server and instead of logoff only by NAV , logged of by Terminal Server leaving NAV always open... :(
  • David_SingletonDavid_Singleton Member Posts: 5,479
    andy76 wrote:
    I think that the real cause was that the user is using NAV in Terminal Server and instead of logoff only by NAV , logged of by Terminal Server leaving NAV always open... :(

    In other words, exactly as I said, the user never actually closed Navision. And remember Change log is in Codeunit 1 before the company is opened, there for you must completely close Navision for any change log changes to take effect.

    ANyway, glad you solved it.
    David Singleton
  • DenSterDenSter Member Posts: 8,305
    To elaborate a little bit:

    Codeunit 1 is a single instance codeunit. When you open NAV, ONE instance is created in memory, and will stay there as long as the session is open. Any changes to the C/AL inside the codeunit will be saved to the database, but will not be reflected in the instance that is already running. To be able to actually run modified code in Codeunit 1, you must close NAV and restart it. This is for instance the reason why you must restart NAS when you make a change, because internally it uses codeunit 1.

    @Andy: Just a friendly word of advice... when someone makes a suggestion, don't just dismiss it, even if it doesn't make sense. There are a LOT of very experienced people in here that have seen most problems before. Even if you think that something is not the cause of a problem, the least you can do is try the suggestion, if only to eliminate the suggestion.
  • andy76andy76 Member Posts: 616
    The problem was that the user confirmed me to exit from NAV but he only exit from TS.
    She is the last one using Terminal Server and didn't remember that.
    I trusted him and was sure he logged out but only now understand that she didn't understand the difference between closing TS or NAV session...
Sign In or Register to comment.