Skip to content

Commit 6d8c403

Browse files
committed
OffsetDateTime now only supports TIMESTAMPZ
1 parent f33b145 commit 6d8c403

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

postgres-types/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ impl WrongType {
398398
/// | `chrono::NaiveDate` | DATE |
399399
/// | `chrono::NaiveTime` | TIME |
400400
/// | `time::PrimitiveDateTime` | TIMESTAMP |
401-
/// | `time::OffsetDateTime` | TIMESTAMP, TIMESTAMP WITH TIME ZONE |
401+
/// | `time::OffsetDateTime` | TIMESTAMP WITH TIME ZONE |
402402
/// | `time::Date` | DATE |
403403
/// | `time::Time` | TIME |
404404
/// | `eui48::MacAddress` | MACADDR |
@@ -661,7 +661,7 @@ pub enum IsNull {
661661
/// | `chrono::NaiveDate` | DATE |
662662
/// | `chrono::NaiveTime` | TIME |
663663
/// | `time::PrimitiveDateTime` | TIMESTAMP |
664-
/// | `time::OffsetDateTime` | TIMESTAMP, TIMESTAMP WITH TIME ZONE |
664+
/// | `time::OffsetDateTime` | TIMESTAMP WITH TIME ZONE |
665665
/// | `time::Date` | DATE |
666666
/// | `time::Time` | TIME |
667667
/// | `eui48::MacAddress` | MACADDR |

postgres-types/src/time_02.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ impl<'a> FromSql<'a> for OffsetDateTime {
4040
Ok(primitive.assume_utc())
4141
}
4242

43-
accepts!(TIMESTAMP, TIMESTAMPTZ);
43+
accepts!(TIMESTAMPTZ);
4444
}
4545

4646
impl ToSql for OffsetDateTime {
@@ -56,7 +56,7 @@ impl ToSql for OffsetDateTime {
5656
primitive.to_sql(type_, w)
5757
}
5858

59-
accepts!(TIMESTAMP, TIMESTAMPTZ);
59+
accepts!(TIMESTAMPTZ);
6060
to_sql_checked!();
6161
}
6262

0 commit comments

Comments
 (0)