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

feat(ui): table autocomplete in sql editor #1744

Merged
merged 4 commits into from
Dec 30, 2021
Merged

Conversation

insmac
Copy link
Contributor

@insmac insmac commented Dec 29, 2021

Summary

This PR adds a table name completion to the SQL editor.

Changelog

  • Using the existing Redux store, added table schema listing to it so it's accessible via selector app-wide.
  • Split questdb-sql language definition file into logical chunks to avoid cluttering.
  • Added two separate completion providers:
    1. questDBCompletionProvider that handles static QuestDB SQL grammar (as before)
    2. schemaCompletionProvider that provides table name completion. This one is disposed every time table schema is updated (i.e. DDL query, click on a refresh button etc) and has a limited set of trigger characters provided.

Features

  • Detect typical table-related syntax
  • Detect QuestDB's SELECT shorthand syntax
  • Update the completion provider once a DDL query is performed or if user refreshes the table schema

Screen recording:

CleanShot.2021-12-29.at.14.56.04.mp4

@bluestreak01 bluestreak01 merged commit 1ba62cf into master Dec 30, 2021
@bluestreak01 bluestreak01 deleted the ui-table-autocomplete branch December 30, 2021 13:45
argshook pushed a commit to questdb/ui that referenced this pull request Jun 8, 2022
argshook pushed a commit to questdb/ui that referenced this pull request Jun 9, 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.

None yet

2 participants