decimal separator

One Star

decimal separator

hi,
I am reading a FileDelimited file and there are values as 2345,56 with french separator "," instead "."
does it exist a facility or options to compute these values ?
thanks for your tips
Highlighted
Employee

Re: decimal separator

Perl component tReplace was introduced in TOS 2.2.0M2 (see 1348)
One Star

Re: decimal separator

thanks for the answer but if possible, I want to preserve my old and very stable 2.1 :-)
Since my issue is very basic, I have tried a small piece of code like:
($row1 =~ s/,/./) * 100.00
but it does not work :-(
is it possible to have an expression to fix the issue ?
One Star

Re: decimal separator

found :-)
(($row1 =~s/,/./)?100:100) * $row1
thanks a lot
Employee

Re: decimal separator

Hi,
You can use the tReplace component with TOS 2.1 since it is available in the ecosystem as an extension : http://www.talendforge.org/ext/extension_view.php?eid=22
You only have to download and unzip the file in your User components folder (defined in Window/Preferences/Talend/Components ) and reload TOS.

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

6 Ways to Start Utilizing Machine Learning with Amazon We Services and Talend

Look at6 ways to start utilizing Machine Learning with Amazon We Services and Talend

Blog

Why Companies Move to the Cloud: 7 Success Stories

Learn how and why companies are moving to the Cloud

Read Now