Difference between revisions of "National Character Sets"

From Recital Documentation Wiki
Jump to: navigation, search
 
Line 61: Line 61:
  
  
Indexes and sorts must use the [[COLLATE()]] function to make use of this alternative collating sequence, and the SET LANGUAGE TO <language-keyword> must be in effect before the index or sort operation is carried out and at all times when any such indexes are being used.  To give system wide National Character Set support, the SET LANGUAGE TO <language-keyword> should be issued in the system [Configuration Files|configuration file]].
+
Indexes and sorts must use the [[COLLATE()]] function to make use of this alternative collating sequence, and the SET LANGUAGE TO <language-keyword> must be in effect before the index or sort operation is carried out and at all times when any such indexes are being used.  To give system wide National Character Set support, the SET LANGUAGE TO <language-keyword> should be issued in the system [[Configuration Files|configuration file]].
  
  
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Reference]]
 
[[Category:Reference]]

Latest revision as of 15:34, 24 March 2009

To enable the use of National Character Sets, the Recital 4GL supports the following functionality:


  • Alternative collating sequences for indexes and sorts
  • The input of 8 bit characters.


These are achieved using the SET LANGUAGE TO <language-keyword> command and in the case of alternative collating sequences, the COLLATE() function.

On execution of the SET LANGUAGE command, the appropriate National Character Set file is loaded from the ’terminals’ directory. The following <languages-keyword> values are supported:


  • AMERICAN
  • BELGIAN
  • BRITISH
  • CHINESE
  • DANISH
  • DUTCH
  • FINNISH
  • FLEMISH
  • FRENCH
  • GERMAN
  • ITALIAN
  • JAPANESE
  • NORWEGIAN
  • RUSSIAN
  • SPANISH
  • SWEDISH


Please note that the <language-keyword> specified is used to reference the appropriate National Character Set file and not to ’switch’ to a particular language. If the <language-keyword> is any of the above, apart from AMERICAN or BRITISH, then 8 bit characters supported by the current terminal will be enabled. For example, SET LANGUAGE TO FRENCH will still allow Russian or German specific characters supported by the current terminal to be entered.


The National Character Set files reside in the ’terminals’ directory and have filenames equivalent to:


<terminal-type>-<first-3-characters-of-language>.ncs


For example, the GERMAN National Character Set file for the VT200 terminal is vt200-ger.ncs.


If the National Character Set file is being used solely to enable 8 bit characters, its contents are disregarded and it can in fact be empty.


To enable alternative collating sequences for indexes and for the SORT command, the National Character Set file must contain the appropriate collating sequence. This consists of ASCII value pairs, the first being the ASCII value of the character, the second its position in the collating sequence, e.g.

97=65

65=66

224=67

192=68

225=69

193=70

226=71


Indexes and sorts must use the COLLATE() function to make use of this alternative collating sequence, and the SET LANGUAGE TO <language-keyword> must be in effect before the index or sort operation is carried out and at all times when any such indexes are being used. To give system wide National Character Set support, the SET LANGUAGE TO <language-keyword> should be issued in the system configuration file.