jadenthem / google-refine

Automatically exported from code.google.com/p/google-refine
0 stars 0 forks source link

Language Translation using Google Refine #266

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
From the following output, from translation(Translate API), how do I extract 
and display just the translated text in a new column? 

handleResponse({ "data": { "translations": [ { "translatedText": "Wall bench in 
base construction, 750 mm high x 2100 wide x 750 mm deep" } ] } } );

Any help on this would be much appreciated.

Thanks!

Original issue reported on code.google.com by jesu.lu...@gmail.com on 29 Nov 2010 at 2:05

GoogleCodeExporter commented 8 years ago
Jesu, this is not an "issue"--it's not a bug or a feature request for the 
product. Rather, it's a question you have.  You should email the group for 
these questions.

But to answer your question here: you should add a new column with this 
expression

value.partition("(")[2].rpartition(")")[0].parseJson().data.translations[0].tran
slatedText

Original comment by dfhu...@gmail.com on 2 Dec 2010 at 7:06

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Thanks a ton! 

Does Google Refine, provide any specific documentation/help for such 
statements? There are some help, online, but it doesn't help on such 
statements. 

Could you advice me on some links for the same? Thanks!

Original comment by jesu.lu...@gmail.com on 2 Dec 2010 at 11:13

GoogleCodeExporter commented 8 years ago
Please email google-refine@googlegroups.com.

Documentation is here: 
http://code.google.com/p/google-refine/wiki/DocumentationForUsers

Original comment by dfhu...@gmail.com on 2 Dec 2010 at 5:01