Expand my Community achievements bar.

SOLVED

Read Document in FileUtilities cannot search a file with french character in the file name

Avatar

Former Community Member

Hi,

I am trying to search a file with french character in the file name like 'captures écran.doc' in my unix server directory, and Write the file somewhere, say in a list of documents or, write on file system to another directory.

I am using to Read Document in FileUtilities of Foundation, but it cannot read the file due to french character in its name. Although it can find any other file name without these french characters.

Tried renaming but that also cannot find the file with french character name.

Please provide any idea to solve it using LC operation.

Regards,

Rohan Raj.

1 Accepted Solution

Avatar

Correct answer by
Former Community Member

Hi Thomas,

Thanks for the post, but I have already found a solution to it a month ago. Sorry for not posting the solution.

You just have to set the '-Djava.property.file.encoding=ISO8859-1' into JVM argument of your server startup, and bounce the server back to pick the new JVM arg set. And now the service Read Document in FileUtilities of Foundation will read all french characters.

ISO8859-1refers to "Latin alphabet no. 1," consisting of 191 characters from the Latin script. This character-encoding scheme is used throughout The Americas,Western Europe, Oceania, and much of Africa. It is also commonly used in most standard romanizations of East-Asian languages.

regards,

Rohan Raj.

View solution in original post

2 Replies

Avatar

Former Community Member

Hi Rohan,

Hope it's not too late ... :/

Did you hardcode the path to your file or did you get it another way ?

What version of LC are you using ?

I'm using LCES2SP2, and if I tried to use the readDocument operation with literal value "C:\capture écran.doc" for example, it worked fine.

Regards,

Thomas

Avatar

Correct answer by
Former Community Member

Hi Thomas,

Thanks for the post, but I have already found a solution to it a month ago. Sorry for not posting the solution.

You just have to set the '-Djava.property.file.encoding=ISO8859-1' into JVM argument of your server startup, and bounce the server back to pick the new JVM arg set. And now the service Read Document in FileUtilities of Foundation will read all french characters.

ISO8859-1refers to "Latin alphabet no. 1," consisting of 191 characters from the Latin script. This character-encoding scheme is used throughout The Americas,Western Europe, Oceania, and much of Africa. It is also commonly used in most standard romanizations of East-Asian languages.

regards,

Rohan Raj.

The following has evaluated to null or missing: ==> liqladmin("SELECT id, value FROM metrics WHERE id = 'net_accepted_solutions' and user.id = '${acceptedAnswer.author.id}'").data.items [in template "analytics-container" at line 83, column 41] ---- Tip: It's the step after the last dot that caused this error, not those before it. ---- Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign answerAuthorNetSolutions = li... [in template "analytics-container" at line 83, column 5] ----