# Transform not working

**URL:** <https://developer.sailpoint.com/discuss/t/transform-not-working/4986>\
**Category:** SHF Discussion and Questions\
**Created:** [July 13, 2022, 2:31pm UTC](https://developer.sailpoint.com/discuss/t/transform-not-working/4986 "2022-07-13T14:31:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![SureshKiran](https://avatars.discourse-cdn.com/v4/letter/s/6f9a4e/32.png) [@SureshKiran](https://developer.sailpoint.com/discuss/u/SureshKiran)\
**Post date:** [July 13, 2022, 2:31pm UTC](https://developer.sailpoint.com/discuss/t/transform-not-working/4986/1 "2022-07-13T14:31:39Z")

</div>

Hi,  
i need to test 3 conditions in the transform, i have written the below transform for testing the conditions but it is not working and the attribute also not showing in the identity attribute list. can you please check the below transform.

```json
{
	"name": "test transform",
	"type": "static",
	"attributes": {
		"values": [{
			"Department": {
				"attributes": {
					"sourceName": "source1",
					"attributeName": "Department"
				},
				"type": "accountAttribute"
			},
			"Company": {
				"attributes": {
					"sourceName": "source2",
					"attributeName": "Company"
				},
				"type": "accountAttribute"
			},
			"Division": {
				"attributes": {
					"sourceName": "source1",
					"attributeName": "Division"
				},
				"type": "accountAttribute"
			},

			"value": "#if($Department=='abc department' && $Company=='abc company' && $Division =='abc division')condition1#{elseif}($Division=='ebc Division' || $Company=='abc company')condition2#{else}Default-conditions#end"

		}]
	}
}

```

---

<div class="post-metadata">

**Author:** ![tyler\_mairose](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/tyler_mairose/32/30112_2.png) [@tyler\_mairose](https://developer.sailpoint.com/discuss/u/tyler_mairose)\
**Post date:** [July 13, 2022, 3:25pm UTC](https://developer.sailpoint.com/discuss/t/transform-not-working/4986/2 "2022-07-13T15:25:09Z")

</div>

Hello @SureshKiran,

The only thing I notice is that you have curly brackets `{}` around the elseif conditional. These are only needed around the final else conditional. Try it without the brackets around the else if.

```json
{
	"name": "test transform",
	"type": "static",
	"attributes": {
		"values": [{
			"Department": {
				"attributes": {
					"sourceName": "source1",
					"attributeName": "Department"
				},
				"type": "accountAttribute"
			},
			"Company": {
				"attributes": {
					"sourceName": "source2",
					"attributeName": "Company"
				},
				"type": "accountAttribute"
			},
			"Division": {
				"attributes": {
					"sourceName": "source1",
					"attributeName": "Division"
				},
				"type": "accountAttribute"
			},

			"value": "#if($Department=='abc department' && $Company=='abc company' && $Division =='abc division')condition1#elseif($Division=='ebc Division' || $Company=='abc company')condition2#{else}Default-conditions#end"

		}]
	}
}

```

---

<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:23pm UTC](https://developer.sailpoint.com/discuss/t/transform-not-working/4986/3 "2023-07-19T14:23:18Z")

</div>


