# Attribute Generator combination

**URL:** <https://developer.sailpoint.com/discuss/t/attribute-generator-combination/8075>\
**Category:** SHF Discussion and Questions\
**Tags:** rules\
**Created:** [February 9, 2023, 3:44pm UTC](https://developer.sailpoint.com/discuss/t/attribute-generator-combination/8075 "2023-02-09T15:44:14Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sansusanmanickan](https://avatars.discourse-cdn.com/v4/letter/s/db5fbb/32.png) [@sansusanmanickan](https://developer.sailpoint.com/discuss/u/sansusanmanickan)\
**Post date:** [February 9, 2023, 3:44pm UTC](https://developer.sailpoint.com/discuss/t/attribute-generator-combination/8075/1 "2023-02-09T15:44:14Z")

</div>

Hello,

On the account profile of the Active Directory, we have two account attributes that are using attribute generator rule.  
The two attributes are : “sAMAccountName” and “mail”  
We want to use at the creation of the AD Account the attribute “sAMAccountName” on the mail creation rule.  
When we try to calculate the mail with the sAMAccountName, the mail is not calculated.  
I want to know if we can use an attribute value that is calculated through a rule on a other attribute who is also calculated through a rule.

Thanks in advance for your answer,

MANICKAN Sansusan

---

<div class="post-metadata">

**Author:** ![sushantkulkarni](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/sushantkulkarni/32/35213_2.png) [@sushantkulkarni](https://developer.sailpoint.com/discuss/u/sushantkulkarni)\
**Post date:** [February 9, 2023, 5:17pm UTC](https://developer.sailpoint.com/discuss/t/attribute-generator-combination/8075/2 "2023-02-09T17:17:33Z")

</div>

You can use the AD before provisioning rule to calculate the email. Only use the generator for sAMAccountName. That way, when the flow reaches before provisioning rule, you can use the generated sAMAccountName value in your email generation logic. You may have to move the generation logic within the before provisioning rule.

---

<div class="post-metadata">

**Author:** ![justinrhaines](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/justinrhaines/32/16564_2.png) [@justinrhaines](https://developer.sailpoint.com/discuss/u/justinrhaines)\
**Post date:** [February 10, 2023, 3:11pm UTC](https://developer.sailpoint.com/discuss/t/attribute-generator-combination/8075/3 "2023-02-10T15:11:29Z")

</div>

If the mail attribute is below the sAMAccountName attribute on the Create Profile, you can use $sAMAccountName@domain.com to reference the value calculated for the sAMAccountName attribute.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/sailpoint/original/2X/f/f2136700ed5e3703e0b85e02f6be799dacca7735.png) [@system](https://developer.sailpoint.com/discuss/u/system)\
**Post date:** [July 19, 2023, 2:24pm UTC](https://developer.sailpoint.com/discuss/t/attribute-generator-combination/8075/4 "2023-07-19T14:24:17Z")

</div>


