We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Submitted by: ded (ded)
Assigned to: @ArnoBrinkman
SFID: 555875# Submitted By: ded
Optimizer rejects explicitly added plan which is built by optimizer itself when query contains OR in where clause and have Primary key.
CREATE TABLE TEST ( ID INTEGER NOT NULL, A INTEGER, B INTEGER);
ALTER TABLE TEST ADD CONSTRAINT PK_TEST PRIMARY KEY (ID);
CREATE INDEX TAB ON TEST (A, B); CREATE INDEX TBA ON TEST (B, A);
SET PLAN;
select * from test where a=1 or b=1;
PLAN (TEST INDEX (TAB,TBA)) - showed plan.
Now trying to explicitly add this plan builded by optimizer
select * from test where a=1 or b=1 PLAN (TEST INDEX (TAB,TBA));
exception 284 index TAB cannot be used in the specified plan
If table have not Primary key plan is accepted. Seems it affects all versions of IB/FB.
Alexander V.Nevsky.
The text was updated successfully, but these errors were encountered:
Workflow: jira [ 10287 ] => Firebird [ 14519 ]
Sorry, something went wrong.
QA Status: No test
No branches or pull requests
Submitted by: ded (ded)
Assigned to: @ArnoBrinkman
SFID: 555875#
Submitted By: ded
Optimizer rejects explicitly added plan which is
built by optimizer itself when query contains OR in
where clause and have Primary key.
CREATE TABLE TEST (
ID INTEGER NOT NULL,
A INTEGER,
B INTEGER);
ALTER TABLE TEST ADD CONSTRAINT PK_TEST PRIMARY KEY
(ID);
CREATE INDEX TAB ON TEST (A, B);
CREATE INDEX TBA ON TEST (B, A);
SET PLAN;
select * from test where a=1 or b=1;
PLAN (TEST INDEX (TAB,TBA))
- showed plan.
Now trying to explicitly add this plan builded by
optimizer
select * from test where a=1 or b=1
PLAN (TEST INDEX (TAB,TBA));
exception 284 index TAB cannot be used in the specified
plan
If table have not Primary key plan is accepted. Seems
it affects all versions of IB/FB.
Alexander V.Nevsky.
The text was updated successfully, but these errors were encountered: