Restricting Row Access

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Simon Faulkner

    #1

    Restricting Row Access

    I am building a small database for our sales reps and each record has
    a repcode field (int)

    I would like to only allow a rep to see their own records and not
    those rows with other repcodes

    Any sugestions as to the best way to achieve this?

    Simon TIA
  • Marshall Barton

    #2
    Re: Restricting Row Access

    Simon Faulkner wrote:
    [color=blue]
    >I am building a small database for our sales reps and each record has
    >a repcode field (int)
    >
    >I would like to only allow a rep to see their own records and not
    >those rows with other repcodes[/color]

    Use forms to display data. You can then filter the form in
    several different way to do what you want.

    Somewhere, you must have a way to determine which rep is
    using the database, once you know that you can use it as a
    parameter in a form's record source query, construct the
    OpenForm's WhereCondition argument or . . ..

    We could provide more specific direction if you'd explain
    more about how your program is set up.

    --
    Marsh

    Comment

    • Simon Faulkner

      #3
      Re: Restricting Row Access

      >We could provide more specific direction if you'd explain[color=blue]
      >more about how your program is set up.[/color]

      I'm beng smart and asking the question before I get started!

      I am storing the data in MySQL (All working fine thanks to the help
      received here earlier :-)

      I have found the currentuser() function so I can construct the query
      as instructed.

      I have the developer tools (Office 2000) and have just managed to get
      the database running on a PC WITH NO MS ACCESS ON IT! Wow :-)

      I guess that this is good because it means that my users can't get to
      a table by accident.

      I have never used the MS Access security tools before (slacker) so I
      guess I will try to get to grips with those now.

      Simon

      Comment

      Working...