Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

$ Expansion and Japanese Characters

So I've got a spreadsheet with some fields containing japanese. I'd like to convert these to english.

The display of the Japanese characters in the QV application is working fine, however when I try to use the field data in a $ expansion, the characters are converted to ASCII ???? characters, not the original japanese characters.

Here is my example call to the google translate api:

//get a google api key @ http://code.google.com/apis/console

LET vGoogleAppsKey = 'pasteGoogleKeyHere';

LET vJapaneseText = '? ? ? ?';


LOAD
'$(vJapaneseText)' as JapaneseText
,@1:n as EnglishTranslated
FROM
[https://www.googleapis.com/language/translate/v2?key=$(vGoogleAppsKey)&q=$(vJapaneseText)&source=ja&target=en]
(fix)
;

Here is the log output:
12/28/2010 1:46:03 PM: 0019 LOAD
12/28/2010 1:46:03 PM: 0020 '? ? ? ?' as JapaneseText
12/28/2010 1:46:03 PM: 0021 ,@1:n as EnglishTranslated
12/28/2010 1:46:03 PM: 0022 FROM
12/28/2010 1:46:03 PM: 0023 [https://www.googleapis.com/language/translate/v2?key=keyGoesHere...&q=? ? ? ?&source=ja&target=en]
12/28/2010 1:46:03 PM: 0024 (fix)

1 Solution

Accepted Solutions
Not applicable
Author

I figured out that I needed to use the applycodepage() function to get the japanese characters to show up.

Something like applycodepage( $(vJapaneseText),932) got it to work!

View solution in original post

1 Reply
Not applicable
Author

I figured out that I needed to use the applycodepage() function to get the japanese characters to show up.

Something like applycodepage( $(vJapaneseText),932) got it to work!