CharSet – PB Docs 126

CharSet database parameter

Description

Specifies the character set you want the Sybase Open Client™ software
to use when connecting to an SAP Adaptive Server Enterprise database
or a database accessed through DirectConnect.

note.png When to specify CharSet

You must specify the CharSet parameter before connecting
to a database.

Controls

  • ASE, SYC SAP Adaptive
    Server Enterprise

  • DIR Sybase DirectConnect

Syntax

Default

None

Usage

When you specify a value for CharSet, PowerBuilder:

  • Allocates a CS_LOCALE
    structure for this connection

  • Sets the CS_SYB_CHARSET value
    to the character set you specify

  • Sets the SQL Server
    CS_LOC_PROP connection property with the new locale
    information

Overriding the Locale parameter

If you have previously set a value for the Locale parameter
that includes settings for the language and character set you want
to use, you can override the character set value by specifying a
new value for the CharSet parameter and reconnecting to the database.

Unicode data access

PowerBuilder can
access Unicode data in an Adaptive Server Enterprise (ASE) 12.5
or later Unicode database or in Unicode columns in ASE 12.5 or later. PowerBuilder converts
between double-byte character set (DBCS) data and Unicode automatically,
provided that the CharSet and Language parameters are set with DBCS
values (or the Locale parameter is set with DBCS values). For example:

Examples

To set the character set to iso_1:

  • Database profile

    Type the following in the Character Set box on the Connection
    page or Regional Settings page in the Database Profile Setup dialog
    box:

  • Application

    Type the following in code:

See Also


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x