Jump to content
Salesforce and other SMB Solutions are coming soon. ×

Adding accounts to another DB


beju0506
 Share

Recommended Posts

Hey, its me again ;)

 

In our DB, we have a setup to create a new user account. We have two databases linked, one Asset database and one DataFiles database. We're trying to script the account addition, but we're having a problem adding the account to the second DB. I've tried opening the second DB, then adding the account, no luck... it tries to add it to the one the original script ran from (AssetDB). Then I tried creating a script in the second DB (DataFiles) to add the account, thinking that the "Add Account" script step would only work in the db the script resides in... still no luck. Does anyone know how to add an account to a separate DB via a script?

 

Thanks!

 

-Justin

Link to comment
Share on other sites

Yes, the Add Account[] script step will need to be run from a script residing in the target file. You'll need to have the privilege sets already in there, then have your New Account script in the target file branch to use a different Add Account[] script step for the particular privilege set you're adding an account to. I used script parameters to send the new account name, privilege set, and password to each file where the account needed to be added.

 

You should also include error trapping, such that if there's a problem adding the account, the error is returned back to the calling file so it can either log it or report it on screen.

Link to comment
Share on other sites

Ender-

 

That was what I was missing, lol... I was sending the info to the script and assuming that the variables I was using would transfer over... so there wasn't anything going into the AddAccount step... no wonder it didn't work... lol :)

Thanks again for your help! (and patience ;))

Link to comment
Share on other sites

 Share



×
×
  • Create New...

Important Information

Terms of Use