This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Need to bulk change Email Addresses

Is there or what is the best way to bulk change Email Addresses from @prod.com to @test.com in a Identity Manager 6.1 UAT system?

  • Hello Blane,

    What table are you looking to update the email for? Is it on the Employee (Person) or AD Account (ADSAccount) record?

    Thanks,
    Roman
  • I believe I will need to change both so that other systems will sync correctly.
  • What do I need to change so that other system update such as ActiveRoles?
  • There are quite a few ways to do this, however I wouldn't recommend using SQL statement directly (i.e. from within SSMS) since it will bypass the object layer and might not trigger updates in the target systems

    You could write a script which has the logic in it to update the email addresses, or even a process with a HandleObjectComponent - Update which can do it (then you trigger the process for all objects on whatever table you want).

    HTH
    Kin
  • Hi Blane,

    If the AD accounts are linked to Employee accounts and the template on ADSAccount.Mail gets it's value from Person.DefaultEmailAddress then you should be able to get away with just changing Person.DefaultEmailAddress.

    The easiest way to do this in bulk in V6 is to use vid_InsertForHandleObject_0.

    A single update would look like this:

    exec vid_InsertForHandleObject_0 'update','person','<whereclause>','DefaultEmailAddress','<new value>',@procid=12345

    You could generate all the updates with a statement like this:

    select 'exec vid_InsertForHandleObject_0 ''update'',''person'',''uid_person='''''+p.uid_person+''''''',''defaultemailaddress'','''+REPLACE(p.defaultemailaddress,'prod.com','test.com')+''',@procid=12345' from Person p where isnull(p.defaultemailaddress,'')<>''

    You can then copy/paste the statements into another query window and run them individually as a test or as a whole.

    HTH, Barry.
  • Barry,

    This is great!

    Thank you