Skip to content

Commit a39aaf6

Browse files
committed
offer get_type api
1 parent dce71d2 commit a39aaf6

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

tokio-postgres/src/client.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -622,6 +622,11 @@ impl Client {
622622
self.inner().clear_type_cache();
623623
}
624624

625+
/// Query for type information
626+
pub async fn get_type(&self, oid: Oid) -> Result<Type, Error> {
627+
crate::prepare::get_type(&self.inner, oid).await
628+
}
629+
625630
/// Determines if the connection to the server has already closed.
626631
///
627632
/// In that case, all future queries will fail.

0 commit comments

Comments
 (0)