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

Supports SHOW FULL TABLES #2372

Closed
killme2008 opened this issue Sep 13, 2023 · 9 comments
Closed

Supports SHOW FULL TABLES #2372

killme2008 opened this issue Sep 13, 2023 · 9 comments
Assignees
Labels
C-enhancement Category Enhancements good first issue Good for newcomers

Comments

@killme2008
Copy link
Contributor

What type of enhancement is this?

API improvement, User experience

What does the enhancement do?

The MySQL supports show full tables:

image

https://dev.mysql.com/doc/refman/8.0/en/show-tables.html

Implementation challenges

No response

@killme2008 killme2008 added C-enhancement Category Enhancements good first issue Good for newcomers labels Sep 13, 2023
@mustachemo
Copy link

Hello, I would like to work on this but I am a bit confused as to what the task is

@killme2008
Copy link
Contributor Author

@mustachemo If you are not familiar with MySQL or Rust, I think it's not a good first issue for you, Thank you.

@Lilit0x
Copy link
Contributor

Lilit0x commented Sep 14, 2023

Hi @killme2008 , I am interested in working on this. Below is a brief description on how I might go about it and where I will start from. Please let me know if I'm wrong or need some other resources to get me up to speed.

  • I understand that there's already a parse_show function after a successful match of Keyword::SHOW here
  • Then the parse_show function checks the next token in which currently, FULL is not recognized, so it throws an error. I plan on adding another case to check if the token is FULL. If it is, move to the next token and also check if it matches TABLES then just return a ShowTables statement with kind of FULL (I will also add this to the enum)
  • Lastly, in the show_tables function in the query handler here is where I will get the tables and get the information about each table to display in the second column.
  • I am not sure on how to get the table type yet, but I can see that the CatalogManager has a table method that returns a Table struct which in turn has a table_type method on it to get the type of the table. I mean here

Thank you.

@killme2008
Copy link
Contributor Author

@Lilit0x Yes, you are right. I assigned the issue to u, thank u.

@Lilit0x
Copy link
Contributor

Lilit0x commented Sep 15, 2023

Hi @killme2008 , I face this error sometimes when I run greptime with cargo run -- standalone start. I can't seem to figure out what the issue is.

greptime_err

@killme2008
Copy link
Contributor Author

Can you delete the data in /tmp/greptimedb?

The new storage engine doesn't implement the recovering properly right now, it will be fixed in #2399

@killme2008
Copy link
Contributor Author

@Lilit0x Sorry, looks like the PR doesn't fix it completely. I created an issue to track it #2407

You have to clean the data dir when you restarted the server, sorry for that, we will fix it ASAP.

@WenyXu
Copy link
Member

WenyXu commented Sep 15, 2023

@Lilit0x I submitted a quick fix in #2408 for this issue. Before it was merged, you can cherry-pick it into your branch.

@killme2008
Copy link
Contributor Author

It's fixed in #2409

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category Enhancements good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants