Transform Script

harshi_ramesh
Tera Expert

Hi All

 

Have written a transform script, before inserting into target table will check if Class is 'PC' or 'Windows'  and if so will restrict the data from getting updated. 

But adding to this, we want a condition which will check if status is 'Disposed' or 'Disabled'. If a record with these are found, instead of updating existing record, it should be able to create one. How to do this?

We have mapped staging table and target table, with coalesce on name and serial number fields. All this working well, but how to get this condition to work with this.

 

Please help with a solution.

 

Thanks

1 ACCEPTED SOLUTION

Pratiksha
Mega Sage
Mega Sage

Their are two ways you can do it. First while inserting the data you can put he condition to check status if it pass create a new one. 

 

Or call IRE in transoform map. 

 

Create a reconsilation rule to make sure the state is not disabled or disposed. 

 

In that way it will check the rule and if it found any records in the state then it will create a new record. 

 

https://www.servicenow.com/community/cmdb-articles/cmdbtransformutil-usage-in-transform-maps/ta-p/26...

 

Rather then transform maps, I would highly recommend to use IH ETL for this. 

 

Hope it helps. 

View solution in original post

5 REPLIES 5

Pratiksha
Mega Sage
Mega Sage

Their are two ways you can do it. First while inserting the data you can put he condition to check status if it pass create a new one. 

 

Or call IRE in transoform map. 

 

Create a reconsilation rule to make sure the state is not disabled or disposed. 

 

In that way it will check the rule and if it found any records in the state then it will create a new record. 

 

https://www.servicenow.com/community/cmdb-articles/cmdbtransformutil-usage-in-transform-maps/ta-p/26...

 

Rather then transform maps, I would highly recommend to use IH ETL for this. 

 

Hope it helps. 

I have written condition to check is status is 'Disposed' or 'Disabled', but record is not getting created. Using transform script because the integration transform map is already set up and working.

Can we do anything?

Thanks for the link, you made my day.

my balance assignments. So I decided to try https://ukwritings.com/write-my-essay and it was a great experience. ukwritings provides essay writing, proofreading, and editing services tailored to students. They prioritize original content, timely delivery, and confidentiality, offering various academic levels and deadlines. I will use this website service for all my upcoming assignments.

Most welcome. Do accept the answer and close the thread. 🙂