AX2012 Copy usage data between users

The usage data is stored in the table SysLastValue. It is saved on userid, so it is easy to copy the data from one user to another.

Before you start the copy it is best that you delete the usage data from the user to which you want to copy.

static void copyUsageDataToAnotherUser(Args _args)
    SyslastValue        syslastOld, syslastNew;

    while select UserId from syslastNew
    where syslastNew.userId == 'AXuser1'
        syslastNew.userId = 'AXuser2';