Skip to main content

RQL Code Assistance

  • All queries sent to the RavenDB server use RQL, RavenDB’s rich query language.
    To learn more about RQL, see What is RQL.

  • RQL Code Assistance is a RavenDB Studio feature that helps you write RQL queries quickly and correctly
    by providing context-aware auto-completion and real-time syntax checking.
    While you type a query in Studio, RQL Code Assistance will:

    • Provide auto-completion (Ctrl+Space) for collections, document fields, indexes, functions, keywords, and operators relevant to your current query context.
    • Update suggestions as you write, showing valid options for the next part of the query.
    • Continuously check syntax and highlight errors with warning icons and detailed messages on hover.
  • RQL Code Assistance is available whenever you write a query in the following Studio views:


Auto-completion

  • To invoke auto-completion, press Ctrl+Space while writing RQL.
    The relevant options for the current cursor location will be listed.

  • Clicking a list item will add it to the query.
    At the very beginning of a query, the suggested options will be the most basic ones:

"Click CTRL+Space to see available options""Click CTRL+Space to see available options"

  1. List of available options
  2. An available option
  3. Option type, which can be -
    • A Collection
    • A Document Field
    • A Function
    • A Keyword
    • An Operator

As the query evolves, new options that are relevant to the current code are suggested.

"Evolving query""Evolving query"

For the collection query shown above, auto-completion presents:

  1. The list of collections that can be queried
  2. The list of keywords that can be used with the selected collection
  3. The list of document fields that can be queried
  4. The list of operators and keywords that can be used

Syntax verification

  • As you write your query, its syntax is continuously verified and errors are detected.
  • When an error is detected, a warning sign is displayed on the left side of the editor.
  • Hovering over the warning sign shows the error details.

"Syntax verification""Syntax verification"

  1. Syntax error (this symbol cannot be used here)
  2. Warning Sign
  3. Error details
    Hover over the warning sign to see the error details.