Skip to content

Commit

Permalink
Merge pull request #13 from Junnplus/field-list
Browse files Browse the repository at this point in the history
  • Loading branch information
sundy-li authored Mar 30, 2022
2 parents b82c432 + f12663c commit 22c7f23
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions mysql/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -561,18 +561,11 @@ impl<B: AsyncMysqlShim<Cursor<Vec<u8>>> + Send + Sync, S: AsyncRead + AsyncWrite
// NOTE: spec dictates no response from server
}
Command::ListFields(_) => {
let cols = &[Column {
table: String::new(),
column: "not implemented".to_owned(),
coltype: myc::constants::ColumnType::MYSQL_TYPE_SHORT,
colflags: myc::constants::ColumnFlags::UNSIGNED_FLAG,
}];
writers::write_column_definitions_41(
cols,
&mut self.writer,
self.client_capabilities,
true,
)?;
// mysql_list_fields (CommandByte::COM_FIELD_LIST / 0x04) has been deprecated in mysql 5.7
// and will be removed in a future version.
// The mysql command line tool issues one of these commands after switching databases with USE <DB>.
// Return a invalid column definitions lead to incorrect mariadb-client behaviour,
// see https://github.com/datafuselabs/databend/issues/4439
let ok_packet = OkResponse {
header: 0xfe,
..Default::default()
Expand Down

0 comments on commit 22c7f23

Please sign in to comment.