Skip to content
This repository was archived by the owner on Jan 14, 2025. It is now read-only.

Commit 0582732

Browse files
conradludgatepimeys
authored andcommitted
offer get_type api
1 parent c849e8a commit 0582732

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
@@ -602,6 +602,11 @@ impl Client {
602602
self.inner().clear_type_cache();
603603
}
604604

605+
/// Query for type information
606+
pub async fn get_type(&self, oid: Oid) -> Result<Type, Error> {
607+
crate::prepare::get_type(&self.inner, oid).await
608+
}
609+
605610
/// Determines if the connection to the server has already closed.
606611
///
607612
/// In that case, all future queries will fail.

0 commit comments

Comments
 (0)