Skip to content

Add \i command to datafusion-cli #1906

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

Closed
matthewmturner opened this issue Mar 2, 2022 · 0 comments · Fixed by #3136
Closed

Add \i command to datafusion-cli #1906

matthewmturner opened this issue Mar 2, 2022 · 0 comments · Fixed by #3136

Comments

@matthewmturner
Copy link
Contributor

Taking inspiration frompsql , it implements a \i command (not a command line argument) for this usecase. It includes a file:

https://www.postgresql.org/docs/13/app-psql.html

\i or \include filename
Reads input from the file filename and executes it as though it had been typed on the keyboard.

If filename is - (hyphen), then standard input is read until an EOF indication or \q meta-command. This can be used to intersperse interactive input with input from files. Note that Readline behavior will be used only if it is active at the outermost level.

It appears that mysql has a similar command source or \. that does the same thing

https://dev.mysql.com/doc/refman/8.0/en/mysql-batch-commands.html

Thus I would recommend implementing a \i command (and possibly also a source command)

Originally posted by @alamb in #1875 (comment)

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 a pull request may close this issue.

1 participant