pub struct SelectModifiers {
pub high_priority: bool,
pub straight_join: bool,
pub sql_small_result: bool,
pub sql_big_result: bool,
pub sql_buffer_result: bool,
pub sql_no_cache: bool,
pub sql_calc_found_rows: bool,
}Expand description
MySQL-specific SELECT modifiers that appear after the SELECT keyword.
These modifiers affect query execution and optimization. They can appear in any order after SELECT and before the column list, can be repeated, and can be interleaved with DISTINCT/DISTINCTROW/ALL:
SELECT
[ALL | DISTINCT | DISTINCTROW]
[HIGH_PRIORITY]
[STRAIGHT_JOIN]
[SQL_SMALL_RESULT] [SQL_BIG_RESULT] [SQL_BUFFER_RESULT]
[SQL_NO_CACHE] [SQL_CALC_FOUND_ROWS]
select_expr [, select_expr] ...See MySQL SELECT.
Fields§
§high_priority: boolHIGH_PRIORITY gives the SELECT higher priority than statements that update a table.
straight_join: boolSTRAIGHT_JOIN forces the optimizer to join tables in the order listed in the FROM clause.
sql_small_result: boolSQL_SMALL_RESULT hints that the result set is small, using in-memory temp tables.
sql_big_result: boolSQL_BIG_RESULT hints that the result set is large, using disk-based temp tables.
sql_buffer_result: boolSQL_BUFFER_RESULT forces the result to be put into a temporary table to release locks early.
sql_no_cache: boolSQL_NO_CACHE tells MySQL not to cache the query result. (Deprecated in 8.4+.)
sql_calc_found_rows: boolSQL_CALC_FOUND_ROWS tells MySQL to calculate the total number of rows. (Deprecated in 8.0.17+.)
Implementations§
Source§impl SelectModifiers
impl SelectModifiers
Sourcepub fn is_any_set(&self) -> bool
pub fn is_any_set(&self) -> bool
Returns true if any of the modifiers are set.
Trait Implementations§
Source§impl Clone for SelectModifiers
impl Clone for SelectModifiers
Source§fn clone(&self) -> SelectModifiers
fn clone(&self) -> SelectModifiers
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SelectModifiers
impl Debug for SelectModifiers
Source§impl Default for SelectModifiers
impl Default for SelectModifiers
Source§fn default() -> SelectModifiers
fn default() -> SelectModifiers
Source§impl<'de> Deserialize<'de> for SelectModifiers
impl<'de> Deserialize<'de> for SelectModifiers
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Display for SelectModifiers
impl Display for SelectModifiers
Source§impl Hash for SelectModifiers
impl Hash for SelectModifiers
Source§impl Ord for SelectModifiers
impl Ord for SelectModifiers
Source§fn cmp(&self, other: &SelectModifiers) -> Ordering
fn cmp(&self, other: &SelectModifiers) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for SelectModifiers
impl PartialEq for SelectModifiers
Source§impl PartialOrd for SelectModifiers
impl PartialOrd for SelectModifiers
Source§impl Serialize for SelectModifiers
impl Serialize for SelectModifiers
Source§impl Visit for SelectModifiers
impl Visit for SelectModifiers
Source§impl VisitMut for SelectModifiers
impl VisitMut for SelectModifiers
Source§fn visit<V: VisitorMut>(&mut self, visitor: &mut V) -> ControlFlow<V::Break>
fn visit<V: VisitorMut>(&mut self, visitor: &mut V) -> ControlFlow<V::Break>
VisitorMut. Read more