Skip to content

Commit 94368c6

Browse files
committed
Fix naming of composite field query
1 parent 91bef8d commit 94368c6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/lib.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ pub mod notification;
100100

101101
const TYPEINFO_QUERY: &'static str = "__typeinfo";
102102
const TYPEINFO_ENUM_QUERY: &'static str = "__typeinfo_enum";
103-
const TYPEINFO_ARRAY_QUERY: &'static str = "__typeinfo_array";
103+
const TYPEINFO_COMPOSITE_QUERY: &'static str = "__typeinfo_composite";
104104

105105
/// A type alias of the result returned by many methods.
106106
pub type Result<T> = result::Result<T, Error>;
@@ -477,7 +477,7 @@ impl InnerConnection {
477477
Err(Error::Conversion(_)) => unreachable!(),
478478
}
479479

480-
match self.raw_prepare(TYPEINFO_ARRAY_QUERY,
480+
match self.raw_prepare(TYPEINFO_COMPOSITE_QUERY,
481481
"SELECT attname, atttypid \
482482
FROM pg_catalog.pg_attribute \
483483
WHERE attrelid = $1 \
@@ -919,7 +919,7 @@ impl InnerConnection {
919919
}
920920

921921
fn read_composite_fields(&mut self, relid: Oid) -> Result<Vec<Field>> {
922-
try!(self.raw_execute(TYPEINFO_ARRAY_QUERY, "", 0, &[Type::Oid], &[&relid]));
922+
try!(self.raw_execute(TYPEINFO_COMPOSITE_QUERY, "", 0, &[Type::Oid], &[&relid]));
923923
let mut rows = VecDeque::new();
924924
try!(self.read_rows(&mut rows));
925925

0 commit comments

Comments
 (0)