create Nav user

ASTAST Member Posts: 108
edited 2007-10-04 in SQL General
Hello,
I need to create new Navision user using only SQL Server (e.g. Management Studio). My client has Navision instaled with one user, for whom I don't know the password. I can't delete this user or chang password for him, so I can't log on and synchronize user id. I have administrator rights in Sql Server.

I use nav 4.03 and sql server 2005

Thanks

Answers

  • nunomaianunomaia Member Posts: 1,153
    To create a new user in Navision you must use Navision cliente and not SQL Server Management Studio
    Nuno Maia

    Freelance Dynamics AX
    Blog : http://axnmaia.wordpress.com/
  • DenSterDenSter Member Posts: 8,307
    If you know the user name that is supposed to be in NAV, and that user is a database user (must be otherwise you can just log in without a password) then you can change the password in SQL Server management studio.
  • WaldoWaldo Member Posts: 3,412
    May be this (dirty) way around is useful.
    You can give your sa account super rights through Management Studio.

    Just go to your database, and to open table "dbo.User" and add SA as a record. Then go to table "dbo.Member Of", and add a record where USERID=SA and ROLE ID=SUPER. This should do it :-k .

    Eric Wauters
    MVP - Microsoft Dynamics NAV
    My blog
  • ASTAST Member Posts: 108
    edited 2007-10-03
    Just go to your database, and to open table "dbo.User" and add SA as a record. Then go to table "dbo.Member Of", and add a record where USERID=SA and ROLE ID=SUPER.
    I tried this way with new user (not sa) and I recived error during logging, but I found another solution
    1) delete previous user form User table (in SQL Server) - in this way you only clear this table not user name and password
    2) create new login and user (I gave him db owner role) in SQL Server
    Now you can log on Navision using your new user (becouse dbo. User table is empty), give this user and previous user a role in Navision and synchronize.
  • WaldoWaldo Member Posts: 3,412
    Actually,

    if you just delete all users from User and Member Of ... you should be able to log into NAV with any user... .

    Eric Wauters
    MVP - Microsoft Dynamics NAV
    My blog
  • ASTAST Member Posts: 108
    Waldo wrote:
    if you just delete all users from User and Member Of ... you should be able to log into NAV with any user... .

    Exactly :)
  • DenSterDenSter Member Posts: 8,307
    Waldo wrote:
    Actually,

    if you just delete all users from User and Member Of ... you should be able to log into NAV with any user... .
    Did you just find the backdoor into NAV???? :shock:
  • nunomaianunomaia Member Posts: 1,153
    DenSter wrote:
    Waldo wrote:
    Actually,

    if you just delete all users from User and Member Of ... you should be able to log into NAV with any user... .
    Did you just find the backdoor into NAV???? :shock:

    In Native you database have the same behaviour. If you don’t have user you can login with any login.
    Nuno Maia

    Freelance Dynamics AX
    Blog : http://axnmaia.wordpress.com/
  • kinekine Member Posts: 12,562
    DenSter wrote:
    Waldo wrote:
    Actually,

    if you just delete all users from User and Member Of ... you should be able to log into NAV with any user... .
    Did you just find the backdoor into NAV???? :shock:

    No, because to do that you needs to have direct access to the MS SQL and it means you do not need NAV to have access because you are admin... ;-)
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • DenSterDenSter Member Posts: 8,307
    nunomaia wrote:
    DenSter wrote:
    Waldo wrote:
    Actually,

    if you just delete all users from User and Member Of ... you should be able to log into NAV with any user... .
    Did you just find the backdoor into NAV???? :shock:

    In Native you database have the same behaviour. If you don’t have user you can login with any login.
    I know that. The backdoor meaning that if you don't have any passwords for a NAV database on SQL Server, you can get in by deleting those records. With the sa password you have access to all databases on SQL Server, but you won't get into a NAV database if SA is not a user in it.
  • WaldoWaldo Member Posts: 3,412
    It is the database administrator that logs into enterprise manager (or management studio). A database administrator should be able to "reset" the security in whatever way. So in that way, it's not really a problem that sa can do this...

    In the way you mean it ... there are always two backdoors:
    - creating the records (for e.g. "sa") in "user" and "member of" tables
    - deleting all records in those tables... .

    Eric Wauters
    MVP - Microsoft Dynamics NAV
    My blog
Sign In or Register to comment.