Guide - aamadeo27/vsqle GitHub Wiki

Table of contents

  1. Configuration

  2. Project Management

  3. Tools

  4. Variables

  5. Results

  6. Execution of Stored Procedures

  7. Select Queries

  8. Analysis

Configuration

In the configuration menu it's specified the information necessary to connect to a VoltDB node

  1. Use Local Time: It shows dates using the local timezone, otherwise it'll display dates in GMT-0.
  2. Enable debug logging : To log debug messages in the console.
  3. Connections: A list of connections, where a connection defines a set of nodes that will use to start a connection to VoltDB.

To log in a server you have to choose a Connection and provide the user/password. Every time a connection to the database is made, the schema in the editor is reloaded.

Project Management

A Project can be created to save folders and files related to it. This data is stored in the localStorage of the browser.

Project Explorer

create-folder-icon Creates a new source folder

delete-icon Deletes the selected object (file or a folder ).

rename-icon Renames the selected object (file or a folder ).

download-project-icon Download a Project

upload-project-icon Upload a Project

Tools

configuration -icon Opens configuration window

reload -icon Reloads schema

execute -icon Execute SQL, executes the tab content or if there's a selection, executes only the selection. Shortcut: F5. Similarly F4 executes the query from the cursor's line to the next ";" or EOF. Example

select * from table_a ;
select * from table_b ; select * from table_c ;
select * from table_d

Asuming the cursor is on 2:5 select * from table_b then F4 executes the query on table_b, if it's on 2:40 it'll execute the query on table_c, if it's on 3:1 it'll execute select * from table_d.

save-icon Saves the tab content to a File. This file is stored in the browser's localStorage.

reload-file-icon Reloads the opened file.

download-icon Download the tab as a sql file.

upload-icon Upload a file into a new tab.

vars-icon Opens variable window.

Variables

Variables can be used in any tab using the syntax ${variableName}.

For example if we have a variable var defined to 'crab', Then we could run select * from animals where name = ${var} and that will run as select * from animals where name = 'crab'

Execution of Stored Procedures

A stored procedure can be invoked using the "exec" command in the form of :

exec <StoredProcedureName> <arg1> <arg2> ... <argN>

Arguments format

Type Example
String 'string-content'
Integer 123456I
Long 123456L
Float 123.456F
Double 123.456D
Timestamp '2014-02-01 10:50:57'T

Select Queries

The select queries by default are specified with "limit 7", so the entire table isn't brought back from the query. In the header of the result are buttons to load the next 7 rows and the rest of the rows.

There's also the option to download the result in CSV, XLS or SQL(insert) formats. Also the result can be copied to a new tab in SQL format or a VoltTableJSON format to a variable that can be used in the invocation of a store procedure*.

*Not currently implemented.

Analysis

It's possible to parse and summarize the information returned of the Stored Procedure @Statistics, using the command analyze <StoredProcedureName> that will summarize the information related to that stored procedure. Divided in per node, per partition, per statement statistics, and general statistics.

⚠️ **GitHub.com Fallback** ⚠️