Results 1 to 5 of 5
  1. #1
    Join Date
    Dec 2008
    Posts
    8

    Unanswered: using one database user or multiple

    In mysql it is very simple to make use of the userfile. Therefore you can create multiple users on different databases and different priveliges. I know with web connections, it is better to use one user for all connection and queries.
    But I delevope a client server application.
    What is the best way to do. We using INNODB for recordlocking.

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    if its a client server application then I'd strongly reccommend one user one userid. so if you have 50 users, thats 50 userids
    I'd rather be riding on the Tiger 800 or the Norton

  3. #3
    Join Date
    Dec 2008
    Posts
    8
    But does mysql knows who locking the record?

  4. #4
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    why would MySQL need to now who was locking the record?
    if your application needs to know who locked the record, then your appliciation needs to provide that to the db. whether you do that as part of an audit record thats up to you

    as to how you identify the user to the db, you do that as part of the connection, through what ever mechanism you are using.... the front end has to estgablish a connection to the db..... normally thats where you would sepcify the userid and password
    I'd rather be riding on the Tiger 800 or the Norton

  5. #5
    Join Date
    Dec 2008
    Posts
    8
    So conclusion:
    - use one database user to connect from client to server on several pc's
    - create an own user file with its own priveliges.
    - use pooling for several connections
    - One client lockes a record and onother client will getting a message by trying to edit it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •