Author Topic: Import structured keywords with special characters  (Read 3148 times)

Offline mpw1950

  • Newcomer
  • *
  • Posts: 27
    • View Profile
Import structured keywords with special characters
« on: May 20, 2021, 05:14:24 AM »
I am trying to import a structured  keyworld file from a txt file of French place names. It all works OK except that accented characters are replaced with a '?' - the characters are corrct in the standard Windows .txt file.

What am I missing? Surely PM supports languiages that use accents?

I am sure I have done it in the past. I ma using the structured keyword panel 'merge' on latest build of PM.

As an aside some synonyms are not shopwing in green but as {whatever} - I suspect a space wherfe it is not needed. I also get a child showing in the right place but in red italics. I am off to chewck my file out, started in Excel, via Word.

Help please.

Martin
« Last Edit: May 20, 2021, 08:56:27 AM by Kirk Baker »

Offline mpw1950

  • Newcomer
  • *
  • Posts: 27
    • View Profile
Re: Import structured keywords with special characters
« Reply #1 on: May 20, 2021, 08:04:06 AM »
I have sorted the synonyms question but still cannot get accented characters to import correctly.

I assume I am correct to enclose multiword keywords in apostrophes to keep phrases together?
« Last Edit: May 20, 2021, 08:56:39 AM by Kirk Baker »

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: Import structured keywords with special characters
« Reply #2 on: May 20, 2021, 08:59:04 AM »
Martin,

I am trying to import a structured  keyworld file from a txt file of French place names. It all works OK except that accented characters are replaced with a '?' - the characters are corrct in the standard Windows .txt file.

What am I missing? Surely PM supports languiages that use accents?

Your text file needs to be encoded in Unicode UTF-8.

As an aside some synonyms are not shopwing in green but as {whatever} - I suspect a space wherfe it is not needed. I also get a child showing in the right place but in red italics. I am off to chewck my file out, started in Excel, via Word.

I suggest not using either of those applications.  The best would be a plain text editor that supports Unicode UTF-8.

-Kirk

Offline mpw1950

  • Newcomer
  • *
  • Posts: 27
    • View Profile
Re: Import structured keywords with special characters
« Reply #3 on: May 21, 2021, 02:47:20 AM »
Kirk,

I had tried that and got a message that it appears to be a binary file. I have attached it.

I have tried again with Wordpad and Notepad, still got the same message about it being an unloadable binary. Do I need to set a preference somewhere?

I was only using Excel & Word in the initial stages to pull the content together, then switched to WordPad to finalise it.

Martin

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: Import structured keywords with special characters
« Reply #4 on: May 21, 2021, 09:13:24 AM »
Martin,

I had tried that and got a message that it appears to be a binary file. I have attached it.

Thanks for providing the file.  It is not UTF-8.  It is UTF-16.  I have corrected that issue and cleaned up the dozens of extraneous tab characters.

I have tried again with Wordpad and Notepad, still got the same message about it being an unloadable binary. Do I need to set a preference somewhere?

No.  It is just that the file is in an incompatible format (UTF-16) and that won't work.

I was only using Excel & Word in the initial stages to pull the content together, then switched to WordPad to finalise it.

Since you're on Windows, I suggest using Notepad++.  It is free and handles UTF-8 just fine.

https://notepad-plus-plus.org/

I noticed that a lot of your terms have single quotes.  I don't know if you wanted that, but they're still there.

-Kirk

Offline mpw1950

  • Newcomer
  • *
  • Posts: 27
    • View Profile
Re: Import structured keywords with special characters
« Reply #5 on: May 21, 2021, 09:22:11 AM »
Thanks Kirk, MS for you it said it was UTF-8!

The single quotes were to keep the phrases intact but I suspect I don't need them.

I have downloaded Notepad++

Just need to get PM Plus working again, see my separate thread. But I mainly us PM clASSIC.

martin