Decimal conversion in Studio 2011
Thread poster: Mervyn Henderson

Mervyn Henderson  Identity Verified
Spain
Local time: 15:55
Member
Spanish to English
+ ...
Oct 15, 2015

Hi,

I've been looking back at past postings on this, but just can't get the configuration of number auto-propagation right to change 123.456 in Spanish to 123,456 in English. I checked Activate auto-prop ..., Confirm segment ... and Always ... - and it took a few minutes to go through the whole text, but now in the target column I have 100% confirmed segments in the original "123.456" format.

What am I doing wrong here? I thought I had this sorted out last year after an explanation by Jerzy, but apparently not.


Best,


Mervyn


Direct link Reply with quote
 

Jerzy Czopik  Identity Verified
Germany
Local time: 15:55
Member (2003)
Polish to German
+ ...
No automatic conversion is working to 100% Dec 20, 2015

Instead of relying on something, which is unreliable, I would use a different option.
Recent Studio version (2015) can deal with numbers much better, but it still has to rely on what is in the source. If the source notation is bad or inconsistent, any automated way will not work.

So if the whole is about number only segments, use display filter, show number only, copy source to target and run a simple search and replace:
Search for a comma , and replace by #. Search for a dot . and replace by comma ,
In the end replace all # by a dot .
If you have numbers in text, leave them in the source format.
After that using Regex for changing the dot and comma will be necessary.
Most probably this simple ones should work:
search for (\d{3})(\.)
replace with \1## (or any other character string you are sure is not appearing in your document)

now replace (\d)(,)(\d)
with \1.\3

and finally replace ## with a comma ,


Direct link Reply with quote
 

Wojciech_
Poland
Local time: 15:55
English to Polish
+ ...
One more option Dec 20, 2015

Do you mean changing all the numbers in one go?
If not, there's one more option. Download Regex Match AutoSuggest Provider.
Then in the app's settings window paste (\d{1,3})\.(\d{1,3}) and in the "Replace Pattern" column paste $1,$2
In this way Autosuggest will automatically change all your 123.456 numbers into 123,456.
Well, not that automatically - by showing the 123,456 in the autosuggest list for you to choose.


Direct link Reply with quote
 

SDL Community  Identity Verified
United Kingdom
Local time: 15:55
English
Possible solutions Dec 21, 2015

Mervyn Henderson wrote:

... to change 123.456 in Spanish to 123,456 in English. I checked Activate auto-prop ..., Confirm segment ... and Always ... - and it took a few minutes to go through the whole text, but now in the target column I have 100% confirmed segments in the original "123.456" format.

What am I doing wrong here? I thought I had this sorted out last year after an explanation by Jerzy, but apparently not.


Hi Mervyn,

I made up a test document with Studio 2011 and a clean TM. Like this it all works fine. However, if I deliberately add a TU into my TM that contains a target using a dot instead of a comma then the auto-propagation will use that dot instead. So perhaps one thing worth checking is that you do not have entries in your TM that are incorrect for this translation.

Then, if you have to go the search and replace route then based on your example you could use:

Search(\d{3})\.(\d{3})

Replace
$1,$2

With regular expressions checked.

Regards

Paul


Direct link Reply with quote
 

Mervyn Henderson  Identity Verified
Spain
Local time: 15:55
Member
Spanish to English
+ ...
TOPIC STARTER
Thanks ... Dec 21, 2015

... Jerzy, pro-lingua and Paul.

Yes, I think the problem is the TM, which is server-based and has been manipulated and mauled by many mitts over the years. There's nothing I can do about that, I think, because it's a huge customer with thousands and thousands of segments already translated, and numbers are a main feature, as it's mostly financial statements.

I do notice that Studio works fine when it's one of my own TMs.


Best,


Mervyn


Direct link Reply with quote
 

SDL Community  Identity Verified
United Kingdom
Local time: 15:55
English
Maybe... Dec 21, 2015

Mervyn Henderson wrote:

I do notice that Studio works fine when it's one of my own TMs.



... you can change the order of priority in your project settings? So add your own TM to the top of the list so that it's the one getting used for this. I had a quick play with a very simplistic setup and this seems to work.

Regards

Paul
SDL Community Support


Direct link Reply with quote
 

Mervyn Henderson  Identity Verified
Spain
Local time: 15:55
Member
Spanish to English
+ ...
TOPIC STARTER
Priority TM Dec 21, 2015

Thanks again Paul, that sounded so interesting I've made a suggestion to the customer:

I've created a "numbers" file, as follows:

+++
1,2
1,23
1,234
1,2345
1.234
12.345
123.456 etc.
++++

i.e. all the possible combinations of a set of Spanish numbers. If I create a new TM and "translate" them all into English as follows:

+++
1.2
1.23
1.234
1.2345
1,234
12,345
123,456 etc.
++++

and then set the resultant TM as the priority TM, it should use it for numbers in tables every time, no matter what mess-ups there are in the main client TM.


Mervyn


Direct link Reply with quote
 


To report site rules violations or get help, contact a site moderator:


You can also contact site staff by submitting a support request »

Decimal conversion in Studio 2011

Advanced search







Déjà Vu X3
Try it, Love it

Find out why Déjà Vu is today the most flexible, customizable and user-friendly tool on the market. See the brand new features in action: *Completely redesigned user interface *Live Preview *Inline spell checking *Inline

More info »
WordFinder Unlimited
For clarity and excellence

WordFinder is the leading dictionary service that gives you the words you want anywhere, anytime. Access 260+ dictionaries from the world's leading dictionary publishers in virtually any device. Find the right word anywhere, anytime - online or offline.

More info »



Forums
  • All of ProZ.com
  • Term search
  • Jobs
  • Forums
  • Multiple search