permissions for Desktop engine

permissions for Desktop engine

Post by Cedric Zaug » Fri, 07 Jun 2002 17:31:48



Hi,

How can I setup usernames and passwords for the Desktop engine without
having the Entreprise Manager installed?

Thanks,
Cedric

 
 
 

permissions for Desktop engine

Post by Dan Guzma » Fri, 07 Jun 2002 22:09:22


You can setup security with system stored procedures and execute these
with the OSQL utility or any ad-hoc SQL application.  The basic steps
are to add the login to SQL Server, grant database access and role
membership (optional).  Below are some untested examples.  See the Books
Online for details.

--add SQL Authentication login
EXEC sp_addlogin 'MyLogin', 'MyPassword'
EXEC sp_defaultdb 'MyLogin', 'MyDatabase'

--add Windows Authentication login (existing Windows user)
EXEC sp_grantlogin 'MyDomain\MyLogin'
EXEC sp_defaultdb 'MyDomain\MyLogin', 'MyDatabase'

USE MyDatabase

--setup object permissions
EXEC sp_addrole 'MyRole'
GRANT ALL ON MyTable TO MyRole

--grant database access
EXEC sp_grantdbaccess 'MyLogin'
EXEC sp_grantdbaccess 'MyDomain\MyLogin'

--add role membership
EXEC sp_addrolemember 'MyRole', 'MyLogin'
EXEC sp_addrolemember 'MyRole', 'MyDomain\MyLogin'

--
Hope this helps.

Dan Guzman
SQL Server MVP

-----------------------
SQL FAQ links (courtesy  Neil Pike):

http://www.ntfaq.com/Articles/Index.cfm?DepartmentID=800
http://www.sqlserverfaq.com
http://www.mssqlserver.com/faq
-----------------------


Quote:> Hi,

> How can I setup usernames and passwords for the Desktop engine without
> having the Entreprise Manager installed?

> Thanks,
> Cedric


 
 
 

permissions for Desktop engine

Post by Cedric Zaug » Fri, 07 Jun 2002 22:57:56


Thanks a lot for your help

Cedric


> You can setup security with system stored procedures and execute these
> with the OSQL utility or any ad-hoc SQL application.  The basic steps
> are to add the login to SQL Server, grant database access and role
> membership (optional).  Below are some untested examples.  See the Books
> Online for details.

> --add SQL Authentication login
> EXEC sp_addlogin 'MyLogin', 'MyPassword'
> EXEC sp_defaultdb 'MyLogin', 'MyDatabase'

> --add Windows Authentication login (existing Windows user)
> EXEC sp_grantlogin 'MyDomain\MyLogin'
> EXEC sp_defaultdb 'MyDomain\MyLogin', 'MyDatabase'

> USE MyDatabase

> --setup object permissions
> EXEC sp_addrole 'MyRole'
> GRANT ALL ON MyTable TO MyRole

> --grant database access
> EXEC sp_grantdbaccess 'MyLogin'
> EXEC sp_grantdbaccess 'MyDomain\MyLogin'

> --add role membership
> EXEC sp_addrolemember 'MyRole', 'MyLogin'
> EXEC sp_addrolemember 'MyRole', 'MyDomain\MyLogin'

> --
> Hope this helps.

> Dan Guzman
> SQL Server MVP

> -----------------------
> SQL FAQ links (courtesy  Neil Pike):

> http://www.ntfaq.com/Articles/Index.cfm?DepartmentID=800
> http://www.sqlserverfaq.com
> http://www.mssqlserver.com/faq
> -----------------------



> > Hi,

> > How can I setup usernames and passwords for the Desktop engine without
> > having the Entreprise Manager installed?

> > Thanks,
> > Cedric

 
 
 

1. Access and Desktop Engine

I  have Access 2000 and have just installed the Desktop Engine.

If I open new project and attempt to create a database using the SQL Server
Wizard, how am I know the user name and password required by the Wizard?

Without it I get the error message "not associated with trusted connection".
If I enter "sa" (which I thought was the default) as the username and no
password  I get the same error message.

If I leave user name and password blank,  then the wizard creates
a database in which "Open", "Design" and "New" are disabled for "Tables",
"Views", "Database Diagrams" and "Stored Procedures". I have no way to
create Tables.

"Microsoft Access 2000 SR-1/SR-1a" has been installed, but I can't find "SQL
Server 2000 Client Tools" and I don't know if this is what I need.

Any clue would be appreciated. Thanks in anticipation.

2. get recordset fields names in a 'tablename.fieldname' format?

3. Creating new database with Desktop Engine and Access

4. How to ORDER results in a Table Function or WITH or correlated table

5. restore backup from sqlserver to desktop engine

6. Which is better for oracle raid 5 or mirrors

7. SQL Server Desktop Engine

8. codds rule 7

9. desktop engine processes

10. Sql CE and MSDE 2000 (Desktop Engine)

11. CAL's & Desktop Engine

12. connecting to SQL Server Desktop Engine

13. Install Full Text at desktop engine