Replace value

More
5 years 2 months ago #20929 by pat.mccarty
Replace value was created by pat.mccarty
Hello,
I am reading from a ODBC source and writing to a txt file. I need to transform a column that when the value is "0" to "000" else just write the value. I have tried several functions and case statements with no luck and closet I can come to it is the Lookup Replace function, but it replaces all "0" with "000"

Example of what I would like to see:
114 = 114
930 = 930
0 = 000

Example of what is happening
114 = 114
930 = 93000
0 = 000

Thank you,
Pat
Attachments:

Please Log in or Create an account to join the conversation.

More
5 years 2 months ago - 5 years 2 months ago #20933 by admin
Replied by admin on topic Replace value
Hi Pat

Thank you for asking such a useful question

It will benefit a lot of users

Since you are replacing just one value the simplest ways it can be done is by using "If Equal to" transformation function.
See attached pictures






Mike
ETL Architect
Attachments:
Last edit: 5 years 2 months ago by admin.

Please Log in or Create an account to join the conversation.

More
5 years 2 months ago #20947 by pat.mccarty
Replied by pat.mccarty on topic Replace value
Thank you, this worked great and awesome solution!

Please Log in or Create an account to join the conversation.

Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Read more
Marketing
Set of techniques which have for object the commercial strategy and in particular the market study.
Google
Accept
Decline
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Google Analytics
Accept
Decline
Functional
Tools used to give you more features when navigating on the website, this can include social sharing.
Advertisement
If you accept, the ads on the page will be adapted to your preferences.
Google Ad
Accept
Decline
Save