A constraint violation occurred - Update AD Object

Ken83
Mega Guru

Hello Community,

I am trying to update the manager for a user in Active Directory. I have referred to several of the other posts here on the community but I have not located anything that addresses this error. The error message is A constraint violation occurred. See below.

find_real_file.png

The values being passed into the object look like this...

find_real_file.png

 

The object name resolves to the sAMAccountName value. The object data resolves to {"manager":"CN=VALUE\, VALUE,OU=VALUE,DC=VALUE,DC=VALUE"}

Any ideas why this would be throwing the error?

 

1 ACCEPTED SOLUTION

Ken83
Mega Guru

I found a solution to this problem. I needed to complete my object in a separate Run Script activity and then JSON.stringify it before setting it on the scratchpad. Then I was able to use the scratchpad value in the Update AD Object activity. Works fine now.

View solution in original post

7 REPLIES 7

Can you post the ecc_queue entries for these attempts, or at least confirm what the MID Server is actually sending over?

Ken83
Mega Guru

I found a solution to this problem. I needed to complete my object in a separate Run Script activity and then JSON.stringify it before setting it on the scratchpad. Then I was able to use the scratchpad value in the Update AD Object activity. Works fine now.

stevemkuk
Tera Contributor

Hi Ken,

You seem to have found the answer to my issue.

I am trying to update the manager for and existing AD user and keep getting 'A constraint violation occurred. HRESULT: [-2147016657] ' errors.

I am not that skilled with Java Script so I know its cheeky but are you able to show exactly what you did? Not sure of the syntax I need to use.

I have been trying for a while now and not getting anywhere!!

Hope you are able to help

Thanks

Steve