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

Keyword completion: Inquire pg_catalog.pg_proc table for scalar functions #401

Open
amotl opened this issue Oct 6, 2023 · 0 comments
Open

Comments

@amotl
Copy link
Member

amotl commented Oct 6, 2023

About

CrateDB offers a PostgreSQL-compatible pg_catalog.pg_proc database system table. It could be used to inquire all scalar function symbols, to add them to the list of keywords provided by the crate.crash.repl.SQLCompleter, similar to how the pg_catalog.pg_get_keywords() function is used to inquire the list of non-function keywords.

Outlook

At GH-360, we also reported:

Some scalar functions like floor or ceil are included within the documentation, but are not part of either pg_catalog.pg_get_keywords() nor the list of fallback keywords [4].
[4] https://github.com/crate/crash/blob/0.27.0/crate/crash/repl.py#L115-L151

In this spirit, other than using pg_catalog.pg_proc, the list of "fallback keywords", or maybe a list of "additional keywords", would probably still need to be maintained, in order to accompany for any gaps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant