TOP をテンプレートにして作成
ホーム
バックアップ
一覧
検索
最終更新
ヘルプ
ログイン
開始行
New Features for Text Data
Table of Contents
New String Functions
New INTL Interface for Non-ASCII Character Sets
New String Functions
LOWER()
TRIM()
New String Size Functions
Two new string functions were added:
LOWER()
A. dos Santos Fernandes
LOWER() returns the input argument converted to all lower...
Example
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set dos850);
SQL> insert into t values ('A');
SQL> insert into t values ('E');
SQL> insert into t values ('Á');;
SQL> insert into t values ('É');
SQL>
C LOWER
====== ======
A a
E e
Á á
É é
TRIM()
A. dos Santos Fernandes
TRIM trims characters (default: blanks) from the left and...
Syntax Pattern
TRIM <left paren> [ [ <trim specification> ] [ <trim char...
FROM ] <value expression> <right paren>
<trim specification> ::= LEADING | TRAILING | BOTH
<trim character> ::= <value expression>
Rules
If <trim specification> is not specified, BOTH is assumed.
If <trim character> is not specified, ' ' is assumed.
If <trim specification> and/or <trim character> is specif...
If <trim specification> and <trim character> is not speci...
Examples
A)
select
rdb$relation_name,
trim(leading 'RDB$' from rdb$relation_name)
from rdb$relations
where rdb$relation_name starting with 'RDB$';
B)
select
trim(rdb$relation_name) || ' is a system table'
from rdb$relations
where rdb$system_flag = 1;
New String Size Functions
A. dos Santos Fernandes
Three new functions will return information about the siz...
BIT_LENGTH returns the length of a string in bits
CHAR_LENGTH/CHARACTER_LENGTH returns the length of a stri...
OCTET_LENGTH returns the length of a string in bytes
Syntax Pattern
These three functions share a similar syntax pattern, as ...
<length function> ::=
{ BIT_LENGTH | CHAR_LENGTH | CHARACTER_LENGTH | OCTET_LEN...
Example
select
rdb$relation_name,
char_length(rdb$relation_name),
char_length(trim(rdb$relation_name))
from rdb$relations;
New INTL Interface for Non-ASCII Character Sets
A. dos Santos Fernandes
Architecture
Enhancements
New Character Sets and Collations Implemented
Character Set Bug Fixes
A feature of Firebird 2 is the introduction of a new inte...
Architecture
Firebird allows character sets and collations to be decla...
At attachment time you can specify the character set that...
Two special character sets, NONE and OCTETS, can be used ...
With other character sets, conversion is performed as CHA...
With NONE/OCTETS the bytes are just copied: NONE/OCTETS->...
Enhancements
Enhancements include:
Well-formedness checks
Some character sets (especially multi-byte) do not accept...
Uppercasing
In FB 1.5.X only ASCII characters are uppercased in a cha...
For example,
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set dos850);
SQL> insert into t values ('a');
SQL> insert into t values ('e');
SQL> insert into t values ('á');
SQL> insert into t values ('é');
SQL>
SQL> select c, upper(c) from t;
C UPPER
====== ======
a A
e E
á á
é é
In FB 2.0 the result is:
C UPPER
====== ======
a A
e E
á Á
é É
Maximum String Length
In FB 1.5.X the engine does not verify the logical length...
This has been retained for compatibility for legacy chara...
sqlsubtype and Attachment Character Set
When the character set of a CHAR or VARCHAR column is any...
Enhancements for BLOBs
Several enhancements have been added for text BLOBs.
COLLATE clauses for BLOBs
A DML COLLATE clause is now allowed with BLOBs.
Example
select blob_column from table
where blob_column collate unicode = 'foo';
Full equality comparisons between BLOBs
Comparison can be performed on the entire content of a te...
Character set conversion for BLOBs
Conversion between character sets is now possible when as...
INTL Plug-ins
Character sets and collations are installed using a manif...
The manifest file should be put in the $rootdir/intl with...
The symbol $(this) is used to indicate the same directory...
Example of a Section from fbintl.conf
<intl_module fbintl>
filename $(this)/fbintl
</intl_module>
<charset ISO8859_1>
intl_module fbintl
collation ISO8859_1
collation DA_DA
collation DE_DE
collation EN_UK
collation EN_US
collation ES_ES
collation PT_BR
collation PT_PT
</charset>
<charset WIN1250>
intl_module fbintl
collation WIN1250
collation PXW_CSY
collation PXW_HUN
collation PXW_HUNDC
</charset>
New Character Sets/Collations
UTF8 character set
The UNICODE_FSS character set has a number of problems: i...
Now, UTF8 is a new character set, without the inherent pr...
UNICODE collations (for UTF8)
UCS_BASIC works identically to UTF8 with no collation spe...
Sort order sample:
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set utf8);
SQL> insert into t values ('a');
SQL> insert into t values ('A');
SQL> insert into t values ('á');
SQL> insert into t values ('b');
SQL> insert into t values ('B');
SQL> select * from t order by c collate ucs_basic;
C
======
A
B
a
b
á
SQL> select * from t order by c collate unicode;
C
======
a
A
á
b
B
Brazilian collations
Two case-insensitive/accent-insensitive collations were c...
Sort order and equality sample:
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set iso8859_1 ...
SQL> insert into t values ('a');
SQL> insert into t values ('A');
SQL> insert into t values ('á');
SQL> insert into t values ('b');
SQL> select * from t order by c;
C
======
A
a
á
b
SQL> select * from t where c = 'â';
C
======
a
A
â
Drivers
New character sets and collations are implemented through...
Not all implemented character sets and collations need to...
Adding More Character Sets to a Database
For installing additional character sets and collations i...
New Character Sets and Collations Implemented
ES_ES_CI_AI for ISO8859_1 Character Set
A. dos Santos Fernandes
Spanish language case- and accent-insensitive collation f...
KOI8-R
O. Loa, A. Karyakin
Russian language character set and dictionary collation.
KOI8-U
O. Loa, A. Karyakin
Ukrainian language character set and dictionary collation.
WIN1257_LV
O. Loa, A. Karyakin
Latvian dictionary collation.
WIN1257_LT
O. Loa, A. Karyakin
Lithuanian dictionary collation.
WIN1257_EE
O. Loa, A. Karyakin
Estonian dictionary collation.
UTF8
A. dos Santos Fernandes
Unicode 4.0 support with UTF8 character set and collation...
Brazilian collations
A. dos Santos Fernandes, P. H. Albanez
Collation PT_BR for ISO8859_character set
Collation WIN_PTBR for WIN1252 character set
Bosnian Collation
F. Hasovic
New Bosnian language collation BS_BA was added for WIN125...
Czech Collations
I. Prenosil, A. dos Santos Fernandes
WIN_CZ: case-insensitive Czech language collation for WIN...
WIN_CZ_CI_AI: case-insensitive, accent-insensitive Czech ...
Vietnamese Character Set
Nguyen The Phuong, A. dos Santos Fernandes
Charset WIN1258 for Vietnamese language.
Polish Collation
Jaroslaw Glowacki, A. dos Santos Fernandes
Added new collation ISO_PLK for ISO8859_2 charset (Polish...
Character Set Bug Fixes
A. dos Santos Fernandes
The following bugs related to character sets and collatio...
SF #1073212 An Order By on a big column with a COLLATE ...
SF #939844 A query in a UNICODE database would throw a ...
SF #977785 Wrong character lengths were being returned ...
SF #536243 A correct result is now returned when the UP...
SF #942726 UPPER did not convert aacute to Aacute for I...
SF #544630 Some problems were reported when connecting ...
SF #540547 Some problems involving concatenation, numer...
Unregistered bug A query could produce different result...
Unregistered bug SUBSTRING did not work correctly with ...
Unregistered bug Pattern matching with multi-byte BLOBs...
Unregistered bug Connecting with a multi-byte character...
最終行:
New Features for Text Data
Table of Contents
New String Functions
New INTL Interface for Non-ASCII Character Sets
New String Functions
LOWER()
TRIM()
New String Size Functions
Two new string functions were added:
LOWER()
A. dos Santos Fernandes
LOWER() returns the input argument converted to all lower...
Example
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set dos850);
SQL> insert into t values ('A');
SQL> insert into t values ('E');
SQL> insert into t values ('Á');;
SQL> insert into t values ('É');
SQL>
C LOWER
====== ======
A a
E e
Á á
É é
TRIM()
A. dos Santos Fernandes
TRIM trims characters (default: blanks) from the left and...
Syntax Pattern
TRIM <left paren> [ [ <trim specification> ] [ <trim char...
FROM ] <value expression> <right paren>
<trim specification> ::= LEADING | TRAILING | BOTH
<trim character> ::= <value expression>
Rules
If <trim specification> is not specified, BOTH is assumed.
If <trim character> is not specified, ' ' is assumed.
If <trim specification> and/or <trim character> is specif...
If <trim specification> and <trim character> is not speci...
Examples
A)
select
rdb$relation_name,
trim(leading 'RDB$' from rdb$relation_name)
from rdb$relations
where rdb$relation_name starting with 'RDB$';
B)
select
trim(rdb$relation_name) || ' is a system table'
from rdb$relations
where rdb$system_flag = 1;
New String Size Functions
A. dos Santos Fernandes
Three new functions will return information about the siz...
BIT_LENGTH returns the length of a string in bits
CHAR_LENGTH/CHARACTER_LENGTH returns the length of a stri...
OCTET_LENGTH returns the length of a string in bytes
Syntax Pattern
These three functions share a similar syntax pattern, as ...
<length function> ::=
{ BIT_LENGTH | CHAR_LENGTH | CHARACTER_LENGTH | OCTET_LEN...
Example
select
rdb$relation_name,
char_length(rdb$relation_name),
char_length(trim(rdb$relation_name))
from rdb$relations;
New INTL Interface for Non-ASCII Character Sets
A. dos Santos Fernandes
Architecture
Enhancements
New Character Sets and Collations Implemented
Character Set Bug Fixes
A feature of Firebird 2 is the introduction of a new inte...
Architecture
Firebird allows character sets and collations to be decla...
At attachment time you can specify the character set that...
Two special character sets, NONE and OCTETS, can be used ...
With other character sets, conversion is performed as CHA...
With NONE/OCTETS the bytes are just copied: NONE/OCTETS->...
Enhancements
Enhancements include:
Well-formedness checks
Some character sets (especially multi-byte) do not accept...
Uppercasing
In FB 1.5.X only ASCII characters are uppercased in a cha...
For example,
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set dos850);
SQL> insert into t values ('a');
SQL> insert into t values ('e');
SQL> insert into t values ('á');
SQL> insert into t values ('é');
SQL>
SQL> select c, upper(c) from t;
C UPPER
====== ======
a A
e E
á á
é é
In FB 2.0 the result is:
C UPPER
====== ======
a A
e E
á Á
é É
Maximum String Length
In FB 1.5.X the engine does not verify the logical length...
This has been retained for compatibility for legacy chara...
sqlsubtype and Attachment Character Set
When the character set of a CHAR or VARCHAR column is any...
Enhancements for BLOBs
Several enhancements have been added for text BLOBs.
COLLATE clauses for BLOBs
A DML COLLATE clause is now allowed with BLOBs.
Example
select blob_column from table
where blob_column collate unicode = 'foo';
Full equality comparisons between BLOBs
Comparison can be performed on the entire content of a te...
Character set conversion for BLOBs
Conversion between character sets is now possible when as...
INTL Plug-ins
Character sets and collations are installed using a manif...
The manifest file should be put in the $rootdir/intl with...
The symbol $(this) is used to indicate the same directory...
Example of a Section from fbintl.conf
<intl_module fbintl>
filename $(this)/fbintl
</intl_module>
<charset ISO8859_1>
intl_module fbintl
collation ISO8859_1
collation DA_DA
collation DE_DE
collation EN_UK
collation EN_US
collation ES_ES
collation PT_BR
collation PT_PT
</charset>
<charset WIN1250>
intl_module fbintl
collation WIN1250
collation PXW_CSY
collation PXW_HUN
collation PXW_HUNDC
</charset>
New Character Sets/Collations
UTF8 character set
The UNICODE_FSS character set has a number of problems: i...
Now, UTF8 is a new character set, without the inherent pr...
UNICODE collations (for UTF8)
UCS_BASIC works identically to UTF8 with no collation spe...
Sort order sample:
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set utf8);
SQL> insert into t values ('a');
SQL> insert into t values ('A');
SQL> insert into t values ('á');
SQL> insert into t values ('b');
SQL> insert into t values ('B');
SQL> select * from t order by c collate ucs_basic;
C
======
A
B
a
b
á
SQL> select * from t order by c collate unicode;
C
======
a
A
á
b
B
Brazilian collations
Two case-insensitive/accent-insensitive collations were c...
Sort order and equality sample:
isql -q -ch dos850
SQL> create database 'test.fdb';
SQL> create table t (c char(1) character set iso8859_1 ...
SQL> insert into t values ('a');
SQL> insert into t values ('A');
SQL> insert into t values ('á');
SQL> insert into t values ('b');
SQL> select * from t order by c;
C
======
A
a
á
b
SQL> select * from t where c = 'â';
C
======
a
A
â
Drivers
New character sets and collations are implemented through...
Not all implemented character sets and collations need to...
Adding More Character Sets to a Database
For installing additional character sets and collations i...
New Character Sets and Collations Implemented
ES_ES_CI_AI for ISO8859_1 Character Set
A. dos Santos Fernandes
Spanish language case- and accent-insensitive collation f...
KOI8-R
O. Loa, A. Karyakin
Russian language character set and dictionary collation.
KOI8-U
O. Loa, A. Karyakin
Ukrainian language character set and dictionary collation.
WIN1257_LV
O. Loa, A. Karyakin
Latvian dictionary collation.
WIN1257_LT
O. Loa, A. Karyakin
Lithuanian dictionary collation.
WIN1257_EE
O. Loa, A. Karyakin
Estonian dictionary collation.
UTF8
A. dos Santos Fernandes
Unicode 4.0 support with UTF8 character set and collation...
Brazilian collations
A. dos Santos Fernandes, P. H. Albanez
Collation PT_BR for ISO8859_character set
Collation WIN_PTBR for WIN1252 character set
Bosnian Collation
F. Hasovic
New Bosnian language collation BS_BA was added for WIN125...
Czech Collations
I. Prenosil, A. dos Santos Fernandes
WIN_CZ: case-insensitive Czech language collation for WIN...
WIN_CZ_CI_AI: case-insensitive, accent-insensitive Czech ...
Vietnamese Character Set
Nguyen The Phuong, A. dos Santos Fernandes
Charset WIN1258 for Vietnamese language.
Polish Collation
Jaroslaw Glowacki, A. dos Santos Fernandes
Added new collation ISO_PLK for ISO8859_2 charset (Polish...
Character Set Bug Fixes
A. dos Santos Fernandes
The following bugs related to character sets and collatio...
SF #1073212 An Order By on a big column with a COLLATE ...
SF #939844 A query in a UNICODE database would throw a ...
SF #977785 Wrong character lengths were being returned ...
SF #536243 A correct result is now returned when the UP...
SF #942726 UPPER did not convert aacute to Aacute for I...
SF #544630 Some problems were reported when connecting ...
SF #540547 Some problems involving concatenation, numer...
Unregistered bug A query could produce different result...
Unregistered bug SUBSTRING did not work correctly with ...
Unregistered bug Pattern matching with multi-byte BLOBs...
Unregistered bug Connecting with a multi-byte character...
ページ名:
新規
名前変更
ホーム
一覧
検索
最終更新
バックアップ
ヘルプ
最終更新のRSS