/vscode-sparql-notebook

Visual Studio Code SPARQL Notebook Extension

Primary LanguageTypeScriptOtherNOASSERTION

VSCode SPARQL Notebook

This extension provides a SPARQL Notebook mode for Visual Studio Code. This is a powerful way to document SPARQL queries and make them execute as notebook code cells.

Use a SPARQL notebook to:

  • Provide hands-on SPARQL training
  • Document data available via SPARQL
  • Validate data via SPARQL

This notebook can render SPARQL SELECT results and RDF graphs via SPARQL CONSTRUCT queries.

sparql-notebook

We recommend using it in conjunction with the Stardog RDF Grammars and SPARQL Language Server for SPARQL syntax highlighting and auto-completion.

This extension is still pretty raw but it works for us [tm]. Bug reports & contributions are very welcome!

Features

  • Open any .sparqlbook file as a Notebook.
  • Execute query blocks in the Notebook UI and view output.
  • Configure endpoint connections in the SPARQL Notebook side panel.

Installation

You can install it directly from the Visual Studio Code Extension tab. It is available on the Marketplace

Usage

Open any .sparqlbook file with the Open With menu option. Then, select the SPARQL Notebook format. Connect to a SPARQL Endpoint and execute query blocks and view output interactively.

FAQ

Show SELECT Results as a Table

Technically that means set the default renderer for MIME-Type application/sparql-results+json.

  1. in the output cell, choose application/sparql-results+json
  2. Open the Command Palette (Ctrl+Shift+P or Cmd+Shift+P on Mac),
  3. Search for "mime" and click: "Notebook: Save Mimetype Display Order"
  4. You will be prompted to choose either to ...
    • enable that default setting globally (choose "User Settings")
    • or locally for that specific workspace (choose "Workspace Settings")

save_mimetype_order

Export as Markdown

Right click a .sparqlbookfile and select Export to Markdown.

Contribute

This extension uses the Notebook API . Contributions & bug fixes are always welcome!