read and read write access to a database

I have an application that needs two users set up with access to a sql database.
one user needs read only to the db
one user needs read-write access to the db.

user 1 has -
server role public
under user mapping the user has public and db datareader roles assigned to the db in question

user 2 has
server role public
under user mapping the user has public and db datareader and db datawriter to the db in question

they both connect using odbc sql driver connection.

the install fails everytime.

are these to users setup with the right permissions if the manual says user 1 to have data reader rights
and user to have read write permissions


am I missing something
jamesmetcalf74Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Vitor MontalvãoMSSQL Senior EngineerCommented:
the install fails everytime.
Which install? You should only create a Login and give them the right permissions on the database.

user 2 has
(...)
 under user mapping the user has public and db datareader and db datawriter to the db in question
Why giving db datareader permission if the requirement is only write permissions?
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
jamesmetcalf74Author Commented:
the setup of this application requires that the db's be created first. I did this creation with the SA account.
 then it goes in and does it setup routine on the db's.  the setup routine requires the two user accounts credentials in question to complete.

I have corrected user two to only write permissions since that should imply reader as implied.
0
jamesmetcalf74Author Commented:
also, the install routine is asking for default named instance.
the name of the instance is the hostname of the server which to me implies that the name is the default

example.
servername apple
instance name is apple        "doesn't this mean that the instance name is the default
0
Vitor MontalvãoMSSQL Senior EngineerCommented:
instance name is apple        "doesn't this mean that the instance name is the default
No. Default instance doesn't have a name. In your case should be apple\apple. But you can check the instances names in SQL Server Configuration Manager.
0
Scott PletcherSenior DBACommented:
I have corrected user two to only write permissions since that should imply reader as implied.

In SQL Server, write permission does not imply read permission.  You should explicitly grant db_datareader if you want this user to also be able to read data.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.