Read Only ODBC Connection

elsandaloselsandalos Member Posts: 4
edited 2007-10-11 in SQL General
Hi all,
Is it possible to create a read-only odbc connection to SQL? We often use odbc to pull NAV data from the SQL tables into MS Access, but as this is a r/w connection there is always the possibility of changing or erasing data from the tables.

I have created an SQL login which only has read access to the tables, but i need a way in Access to force this to be used - otherwise a user could just login to the connection using their usual r/w NAV login details.

cheers

El.

Comments

  • ara3nara3n Member Posts: 9,256
    The regular users should only have public role on sql.
    This role does not allow any select statements to be run.
    So they should be able to to do r/w with their usual login.

    Creating a new login with just read access is the correct choice.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
  • kinekine Member Posts: 12,562
    Or you can create views for just the tables and columns you want to publish and set the permissions to these views. In this case you will make transparent interface for the users and you will not risk access directly to the data. And it will be easier to manage the connection in case of renaming tables or company (you just redefine the views).
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
Sign In or Register to comment.