Struct sql_parser::ast::IntervalValue [−][src]
pub struct IntervalValue {
pub value: String,
pub precision_high: DateTimeField,
pub precision_low: DateTimeField,
pub fsec_max_precision: Option<u64>,
}
Expand description
An intermediate value for Intervals, which tracks all data from the user, as well as the computed ParsedDateTime.
Fields
value: String
The raw [value]
that was present in INTERVAL '[value]'
precision_high: DateTimeField
The most significant DateTimeField to propagate to Interval in compute_interval.
precision_low: DateTimeField
The least significant DateTimeField to propagate to Interval in
compute_interval.
precision_low is also used to provide a TimeUnit if the final
part of value
is ambiguous, e.g. INTERVAL ‘1-2 3’ DAY uses
‘day’ as the TimeUnit for 3.
fsec_max_precision: Option<u64>
Maximum nanosecond precision can be specified in SQL source as
INTERVAL '__' SECOND(_)
.
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for IntervalValue
impl Send for IntervalValue
impl Sync for IntervalValue
impl Unpin for IntervalValue
impl UnwindSafe for IntervalValue
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key
and return true
if they are equal.
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more