1. Michael Kramer
  2. PowerBuilder
  3. Sunday, 15 September 2019 18:29 PM UTC

Hi All,

  • What Unicode version is used in PowerScript compiler for PB 2017 and forward?
  • What Unicode character categories are valid in identifiers?

Jon Skeet's 2014 blog on the Mongolian Vowel Separator got me thinking of PowerScript and Unicode. Introduced in PB 10 (2005) it could be PowerScript compiler still uses whatever version was selected when product development for PB 10 started.

Re: Identifiers

F1-Help states "letters" and a few special characters. In PB 2019 letters include accented letters, Nordic letters, Greek, Cyrillic, and probably quite a few more categories. Special chars also extended (I found €, £, ¥, and § but neither ₫ nor ₨)

Mongolian Vowel Separator? It acts as invisible white space => Don't use it for code!

Thanks, /Michael

Roland Smith Accepted Answer Pending Moderation
  1. Monday, 16 September 2019 00:06 AM UTC
  2. PowerBuilder
  3. # 1

I don't see why PowerBuilder would care what the contents of the string are. A unicode character is a unicode character. Any character that can be represented in UTF-16LE should be supported.

As long as the font used supports the character, you should be able to display it.

Comment
  1. Michael Kramer
  2. Monday, 16 September 2019 16:50 PM UTC
I'm confident PB displays whatever Unicode character I throw at it.

I'm more curious how the shift to Unicode in PB 10 impacts identifier rules (I know 12 years late). Like naming price for different currencies using currency symbol. Used to be $ only. Now more, e.g. ldec_price£ and ldec_price€ but not using Rupee symbol.

So I wondered if there are specific Unicode categories that are valid. Such decision possibly taken early 2000s.
  1. Helpful
  1. Roland Smith
  2. Monday, 16 September 2019 17:46 PM UTC
You are actually talking about use of Unicode characters in variable names. I think the only way to find out is to try it yourself. I doubt Sybase bothered to do anything in that area and if they did, I doubt they documented it anywhere.
  1. Helpful
  1. Chris Pollach @Appeon
  2. Monday, 16 September 2019 18:05 PM UTC
Hi Roland;

AFAIK, the PB internal names are the same as PowerSoft originally designed them. English characters up to 40 characters (32 character names are much safer).

Note: Sybase started to change the name length to 255 characters but did not succeed in completing this task in all areas of the PB IDE and/or compilers.

Regards ... Chris
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Sunday, 15 September 2019 18:57 PM UTC
  2. PowerBuilder
  3. # 2

Hi Michael;

   UTF-16LE ... Same as MS-Windows.

Regards... Chris

Comment
  1. Chris Pollach @Appeon
  2. Sunday, 15 September 2019 19:20 PM UTC
Unicode was introduced in PB 10 just after 1999 when Unicode 3.0 standard was introduced. I can't remember any updates to that feature since then. So I'm going to go out on a limb here and say Appeon PB (using what PB12.6 had when Appeon took over PB from Sybase) is still the same implementation. So that's the Unicode 3.0 standard in my mind.
  1. Helpful
  1. Michael Kramer
  2. Sunday, 15 September 2019 21:03 PM UTC
THX, My presumption but thanks for "verifying".

I would retain Unicode version until PowerScript has major language overhaul.

Architecture: PowerScript vs. REST service is "protected" by JSON being the data transmission "language".

The Mongolian Vowel Separator is uncommon though it highlights standards-based data exchange has cornercases in real world.

/Michael
  1. Helpful
  1. Roland Smith
  2. Monday, 16 September 2019 18:54 PM UTC
This is valid:



String ls_#$%¢£§©₡



Your best bet is to just try it and see what happens. Mongolian Vowel Separator gives an error.
  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.