Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replication/Security Questions

Status
Not open for further replies.

Bell1991

Programmer
Aug 20, 2003
386
US
I have a couple of questions. First, I am writing a program to (hopefully) do everything i nomally do in SQL Server. I think in some cases it will be easier to do it that way.

First thing i was wondering, is there any to set up replication? I currently have it set up - but as i add in additional databases i would like to be able to set it up. Is there a stored procedure or something i can call?

Secondly, is there anyway to access the security Logins (i.e., i want to add a new user to a database and set the properties?)

Any suggestions?

Thanks in advance!
-Bell
 
Almost everything done in EM can be done with Stored procedures.

sp_addlogin will get you started for the security. you can then manually add everthing you need. other ones you may need are sp_password, Grant,sp_grantdbaccess, sp_addrolemember, sp_addsrvrolemember, sp_grantlogin

as for replication, i would stay within em. but if you really want to work with it, thre are differnt stored procedures for differnt types. for example sp_addpullsubscription is for adding pull subscriptions. just take a look through books online.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top