pub enum IndexChoice {
Any,
NotIndexed,
Only(Vec<u8>),
}Expand description
Which indexes the planner may use for one FROM term.
SQLite’s two clauses are opposite restrictions and the planner reads them
in one place, choose_path. NOT INDEXED takes every index away and leaves
the rowid. INDEXED BY takes everything else away, the rowid and the
table scan included: the pinned 3.53.4 shell plans
SELECT * FROM h INDEXED BY h_a WHERE id = 5 as SCAN h USING INDEX h_a,
a walk of the whole index, with a rowid seek sitting unused beside it.
Variants§
Any
Nothing was written, so every path is a candidate.
NotIndexed
NOT INDEXED: no index, and the rowid is still allowed.
Only(Vec<u8>)
INDEXED BY name: that index and nothing else, by its folded name.
Trait Implementations§
Source§impl Clone for IndexChoice
impl Clone for IndexChoice
Source§impl Debug for IndexChoice
impl Debug for IndexChoice
Source§impl Default for IndexChoice
impl Default for IndexChoice
impl Eq for IndexChoice
Source§impl PartialEq for IndexChoice
impl PartialEq for IndexChoice
impl StructuralPartialEq for IndexChoice
Auto Trait Implementations§
impl Freeze for IndexChoice
impl RefUnwindSafe for IndexChoice
impl Send for IndexChoice
impl Sync for IndexChoice
impl Unpin for IndexChoice
impl UnsafeUnpin for IndexChoice
impl UnwindSafe for IndexChoice
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more