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

Restoring DB with computed index on computed field provides wrong index and wrong select results [CORE2440] #2855

Closed
firebird-automations opened this issue Apr 23, 2009 · 18 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: @cincuranet

Jira_subtask_outward CORE2448
Is duplicated by CORE5118
Is duplicated by CORE5800

Attachments:
bak.bak

Attached is backup of database. If you restore it and run "select id from prislusenstvi order by upper(title)" you get wrong result. If you look at the index IDX_PRISLUSENSTVI_UPPER_TITLE it's wrong. After recreating the index, everything is OK.

Commits: dfc0259 fea7c61 a741300 ebd0bcf 98aafa7

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

See test for CORE5118.
Bug was fixed, ticket CORE2440 can be closed.

@firebird-automations
Copy link
Collaborator Author

Modified by: @cincuranet

Attachment: bak.bak [ 11444 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

security: Developers [ 10012 ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @cincuranet

Please keep the ticket restricted, the database isn't for public.

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

assignee: Vlad Khorsun [ hvlad ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @hvlad

At restore, indices are activated before the commit of transaction within which computed fields are updated with its BLR. Therefore expression index not see correct BLR of computed field on which index is depends. As result such expression index is built using empty key values.

Fix is to commit computed fields transaction before activation of indices.

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

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

resolution: Fixed [ 1 ]

Fix Version: 2.5 RC1 [ 10300 ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @dyemanov

The ticket is reopened because:
1) It doesn't solve the reported issue when a database is restored *without* the -verbose switch.
2) It breaks restore for any database that has user-defined plans embedded into procedures/triggers and the restore is performed *with* the -verbose switch.

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

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

resolution: Fixed [ 1 ] =>

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

Fix Version: 2.5 Beta 2 [ 10300 ] =>

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

security: Developers [ 10012 ] =>

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

Link: This issue is duplicated by CORE5118 [ CORE5118 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

Link: This issue is duplicated by CORE5800 [ CORE5800 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

assignee: Vlad Khorsun [ hvlad ] => Dmitry Yemanov [ dimitr ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

status: Reopened [ 4 ] => In Progress [ 3 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

status: In Progress [ 3 ] => Open [ 1 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @dyemanov

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

resolution: Fixed [ 1 ]

Fix Version: 4.0 Beta 1 [ 10750 ]

Fix Version: 2.5.9 [ 10862 ]

Fix Version: 3.0.5 [ 10885 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

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

QA Status: Covered by another test(s)

Test Details: See test for CORE5118.
Bug was fixed, ticket CORE2440 can be closed.

@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