Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Programmatically creating a logon userid in SQL2000

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-05-30 : 08:51:50
Michael writes "We have developed an application which attaches tables via ODBC using our own userid called MIKROFAX which we have given db_owner privs to. This is OK in NT/2K/XP with a grown up copy of SQL but doesnt work when you run SQLServer2000 Desktop Edition as you only get a default logon of SA. End-users will not have the Enterprise Manager loaded.

So - my question (I think) is how can I programmatically (in VB) create a new user Logon called MIKROFAX with db_owner privs which will allow my app to login and connect to the database !

Is it something to do with the SQLDMO object ?

e.g. Set osvr = CreateObject("SQLDMO.SQLServer") ?

If so ... what ?

Thanks

Mike
Mikep45@hotmail.com"

RickD
Slow But Sure Yak Herding Master

3608 Posts

Posted - 2002-05-30 : 09:51:43
Connect to the master, use sp_addlogin... done.....

Please tell if I missed something here.....

Rick

Go to Top of Page

Nazim
A custom title

1408 Posts

Posted - 2002-06-01 : 00:55:22
yeah, couple of months of SQLTeam
quote:

Please tell if I missed something here.....




--------------------------------------------------------------


Edited by - Nazim on 06/01/2002 08:43:14
Go to Top of Page
   

- Advertisement -