-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[YSQL] Expose primary key as an index #955
Labels
kind/enhancement
This is an enhancement of an existing feature
Comments
robertpang
added
the
kind/enhancement
This is an enhancement of an existing feature
label
Mar 7, 2019
yugabyte-ci
pushed a commit
that referenced
this issue
Mar 31, 2019
Summary: Primary key of a YSQL table is now handled as a table index so that it can be used in an index scan path. The current ybc_fdw scan path becomes a simple sequential scan. Test Plan: Jenkins Reviewers: neil, neha, mihnea Reviewed By: mihnea Subscribers: yql Differential Revision: https://phabricator.dev.yugabyte.com/D6326
Resolved in commit be0908b. |
yugabyte-ci
pushed a commit
that referenced
this issue
Apr 4, 2019
Summary: D6326 (#955) implemented handling primary key as an index so that in can be used in an index scan path. As a side-effect it caused single-row inserts to be mis-categorized as multi-row operations causing them to use the distributed txns path (instead of the single row txn path). This fixes the relevant check. Test Plan: java -jar ./target/yb-sample-apps.jar --workload SqlInserts --nodes 127.0.0.1:5433 --num_threads_write 24 --num_threads_read 0 --num_unique_keys 1000000000 Reviewers: robert Reviewed By: robert Subscribers: yql Differential Revision: https://phabricator.dev.yugabyte.com/D6437
yugabyte-ci
pushed a commit
that referenced
this issue
Apr 23, 2019
Summary: We already have UNIQUE index support, and all work necessary for UNIQUE constraint support was essentially done by @robert in #955 All that was left to do was to enable UNIQUE constraint in grammar and add test coverage. Test Plan: ./yb_build.sh release --java-test org.yb.pgsql.TestPgUniqueConstraint Reviewers: mikhail, neil, robert Reviewed By: robert Subscribers: neha, mihnea, robert, yql Differential Revision: https://phabricator.dev.yugabyte.com/D6458
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Currently, when a table is created with a primary key in YSQL, the primary key is used internally by YugaByte and is not exposed to Postgres. We should expose it so that it can take part in Postgres' query planning explicitly.
The text was updated successfully, but these errors were encountered: