pub enum IntervalStyle {
PostgresVerbose,
SQLStandard,
MySQL,
}Available on crate feature
unparser only.Expand description
IntervalStyle to use for unparsing
https://www.postgresql.org/docs/current/datatype-datetime.html#DATATYPE-INTERVAL-INPUT different DBMS follows different standards, popular ones are: postgres_verbose: ‘2 years 15 months 100 weeks 99 hours 123456789 milliseconds’ which is compatible with arrow display format, as well as duckdb sql standard format is ‘1-2’ for year-month, or ‘1 10:10:10.123456’ for day-time https://www.contrib.andrew.cmu.edu/~shadow/sql/sql1992.txt
Variants§
Trait Implementations§
Source§impl Clone for IntervalStyle
impl Clone for IntervalStyle
Source§fn clone(&self) -> IntervalStyle
fn clone(&self) -> IntervalStyle
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for IntervalStyle
Auto Trait Implementations§
impl Freeze for IntervalStyle
impl RefUnwindSafe for IntervalStyle
impl Send for IntervalStyle
impl Sync for IntervalStyle
impl Unpin for IntervalStyle
impl UnwindSafe for IntervalStyle
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more