Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for MEDIUMBLOB and CHAR #2

Merged
merged 2 commits into from
Aug 22, 2022

Conversation

yonran
Copy link
Contributor

@yonran yonran commented Mar 18, 2020

  • Add ability to read MEDIUMBLOB columns (previously panicked)
  • Make the Vec in Blob(Vec<u8>) public so that you can read the BLOB or TEXT data
  • Add ability to read CHAR(n) columns (previously panicked) by parsing the MYSQL_TYPE_STRING length according to log_event_print_value in log_event.cc (which is the reference according to MySQL Internals Manual -> The Binary Log -> Event Data for Specific Event Types)
  • Don’t panic when a column has a BINARY(n) column (previously panicked), although the byte data is currently lost
  • Fix the numbering of ColumnType::Set and ColumnType::TinyBlob in ColumnType::from_byte to match mysql-server’s field_types.cc

src/column_types.rs Outdated Show resolved Hide resolved
@Roguelazer
Copy link
Contributor

This looks reasonable; can you rebase on master (sorry for all the conflicts)?

@Justintime50
Copy link
Member

@yonran are you able to rebase against master?

@yonran
Copy link
Contributor Author

yonran commented Sep 29, 2021

@Justintime50 sure I just rebased it

Add support for parsing CHAR(n) columns

BINARY(n) columns no longer cause a panic, but the value is not usable (since it is converted to utf-8).

SET and ENUM columns no longer panic in read_metadata, but they still panic in read_value
@Roguelazer Roguelazer merged commit 8257d06 into EasyPost:master Aug 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants