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

fix: 'unsupported command' everywhere #664

Merged
merged 1 commit into from
Jun 25, 2022

Conversation

cadl
Copy link
Contributor

@cadl cadl commented Jun 25, 2022

Signed-off-by: cadl ctrlaltdeleteliu@gmail.com

After #662, the internal command does not work. Make some fixes.

before:

> \dt
? ;
Internal error: unsupported command
> \dt;
Internal error: unsupported command
>

after:

> \dt
+---+----------+---+------------+---+--------------+
| 0 | postgres | 1 | pg_catalog | 0 | contributors |
+---+----------+---+------------+---+--------------+
in 0.001s
> select * from foo;
bind error: invalid table foo
> select *
? from foo;
bind error: invalid table foo

Signed-off-by: cadl <ctrlaltdeleteliu@gmail.com>
Copy link
Collaborator

@TennyZhuang TennyZhuang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Copy link
Member

@skyzh skyzh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! In fact, I think \dt should always work without ;. That is to say, if a line begins with \, then the cli should immediately execute it on new line instead of waiting for ;. If you're interested, you may submit another PR to fix the behavior.

@skyzh skyzh merged commit f5a7049 into risinglightdb:main Jun 25, 2022
@cadl
Copy link
Contributor Author

cadl commented Jun 25, 2022

Thanks! In fact, I think \dt should always work without ;. That is to say, if a line begins with \, then the cli should immediately execute it on new line instead of waiting for ;. If you're interested, you may submit another PR to fix the behavior.

yes, \dt works like you say now. As the example in the PR description

> \dt
+---+----------+---+------------+---+--------------+
| 0 | postgres | 1 | pg_catalog | 0 | contributors |
+---+----------+---+------------+---+--------------+
in 0.001s

@cadl cadl deleted the let-internal-cmd-comeback branch June 25, 2022 15:57
@skyzh
Copy link
Member

skyzh commented Jun 25, 2022

That's cool, thanks!

xinchengxx pushed a commit to xinchengxx/risinglight that referenced this pull request Jul 12, 2022
Signed-off-by: cadl <ctrlaltdeleteliu@gmail.com>
Signed-off-by: xinchengforgit <2419743144@qq.com>
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.

3 participants