Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FB3 - crash (consistency check) when creating view on table which has column with character set none, database default charset is utf8, and utf8 default collation is 'unicode'. [CORE5448] #5719

Closed
firebird-automations opened this issue Jan 11, 2017 · 11 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: Zoran Vučenović (zoran.vucenovic)

Attachments:
isql-screenshot.png

Please do the following four steps in FB 3.0.1:

/* 1. Create new database and set utf8 to be the default char set (change db path to whatever you want, in my example "test1" is an alias defined in database.conf) */
create database 'inet://localhost/test1' default character set utf8;

/* 2. set default collation of utf8 to be unicode */
alter character set utf8 set default collation unicode;

/* 3. create table with a field which has character set none */
create table table1
(
fld1 char(1) character set none
);

/* 4. Now, try to create view which reads this field */
create view view1
as
select fld1 from table1
;

After this, you get:

Statement failed, SQLSTATE = XX000
internal Firebird consistency check (pointer page lost from DPM_delete_relation (246), file: dpm.cpp line: 1159)

And database seems to be corrupted afterwards.

There is no such problem with FB 2.5. I am prepairing to migrate my databases to FB 3, but because of this bug, I'm still remaining on 2.5.6.

Commits: 1a075b8 a5f73c5

====== Test Details ======

See test for CORE5846 (it was made on this ticket basis).

@firebird-automations
Copy link
Collaborator Author

Modified by: Zoran Vučenović (zoran.vucenovic)

description: Please do the following for steps in FB 3.0.1:

/* 1. Create new database and set utf8 to be the default char set (change db path to whatever you want, in my example "test1" is an alias defined in database.conf) */
create database 'inet://localhost/test1' default character set utf8;

/* 2. set default collation of utf8 to be unicode */
alter character set utf8 set default collation unicode;

/* 3. create table with a field which has character set none */
create table table1
(
fld1 char(1) character set none
);

/* 4. Now, try to create view which reads this field */
create view view1
as
select fld1 from table1
;

After this, you get:

Statement failed, SQLSTATE = XX000
internal Firebird consistency check (pointer page lost from DPM_delete_relation (246), file: dpm.cpp line: 1159)

And database seems to be corrupted afterwards.

There is no such problem with FB 2.5. I am prepairing to migrate my databases to FB 3, but because of this bug, I'm still remaining on 2.5.6.

=>

Please do the following four steps in FB 3.0.1:

/* 1. Create new database and set utf8 to be the default char set (change db path to whatever you want, in my example "test1" is an alias defined in database.conf) */
create database 'inet://localhost/test1' default character set utf8;

/* 2. set default collation of utf8 to be unicode */
alter character set utf8 set default collation unicode;

/* 3. create table with a field which has character set none */
create table table1
(
fld1 char(1) character set none
);

/* 4. Now, try to create view which reads this field */
create view view1
as
select fld1 from table1
;

After this, you get:

Statement failed, SQLSTATE = XX000
internal Firebird consistency check (pointer page lost from DPM_delete_relation (246), file: dpm.cpp line: 1159)

And database seems to be corrupted afterwards.

There is no such problem with FB 2.5. I am prepairing to migrate my databases to FB 3, but because of this bug, I'm still remaining on 2.5.6.

@firebird-automations
Copy link
Collaborator Author

Commented by: Zoran Vučenović (zoran.vucenovic)

I'm attaching the screenshot.
Please, take a look.

@firebird-automations
Copy link
Collaborator Author

Modified by: Zoran Vučenović (zoran.vucenovic)

Attachment: isql-screenshot.png [ 13053 ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @pavel-zotov

Confirmed on WI-T4.0.0.494\

SQL> create database 'localhost:C:\FBTESTING\qa\fbt-repo\tmp\c5448.fdb' default character set utf8;
SQL> alter character set utf8 set default collation unicode;
SQL> create table table1
CON> (
CON> fld1 char(1) character set none
CON> );
SQL> create view view1
CON> as
CON> select fld1 from table1
CON> ;
Statement failed, SQLSTATE = XX000
internal Firebird consistency check (pointer page lost from DPM_delete_relation (246), file: dpm.cpp line: 1149)

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

assignee: Vlad Khorsun [ hvlad ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @hvlad

The bugcheck reason is fixed (thus i consider this ticket as fixed) but there is another problem:

SQL> create view view1
CON> as
CON> select fld1 from table1;
Statement failed, SQLSTATE = 42000
unsuccessful metadata update
-VIEW1
-Implementation of text subtype 512 not located.

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 3.0.2 [ 10785 ]

Fix Version: 4.0 Alpha 1 [ 10731 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Resolved [ 5 ]

QA Status: No test => Deferred

Test Details: see here issue 07.02.2017 0915

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Resolved [ 5 ]

Test Details: see here issue 07.02.2017 0915 => see here issue 02.02.2017 by Vlad

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Resolved [ 5 ]

QA Status: Deferred => Covered by another test(s)

Test Details: see here issue 02.02.2017 by Vlad => See test for CORE5846 (it was made on this ticket basis).

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Closed [ 6 ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants