The SQL Anywhere Tools project is a comprehensive suite of tools designed to simplify and streamline the management and development of SAP SQL Anywhere 17 databases. This project consists of a set of CLI tools for common database operations and a VSCode extension that integrates all of these tools into a seamless development environment.
By bundling both command-line utilities and an integrated VSCode experience in a single monorepo, this toolbox enables developers and DBAs to perform essential tasks more efficiently, whether working directly with the command line or within their IDE.
- SQL Anywhere Tools - Complete toolbox for SAP SQL Anwyhere 17
- Project Description
- Table Of Contents
- Feature Roadmap
- Installation
- Usage
- Development
- License
- sqlanydb-manager CLI tool: start, stop, reset and ping local databases [X]
- accompanying feature support in sqlanydb-tools-vscode extension [X]
- database connector through sajdbc4.jar & dbjdbc17.jar included with sql anywhere [ ]
- accompanying feature support to run queries in sqlanydb-tools-vscode extension [ ]
- sql anywhere language parser with ANTLR [ ]
- accompanying syntax highlighting in sqlanydb-tools-vscode extension [ ]
- prettier-plugin-sqlanydb for sql anywhere auto formatting support [ ]
- LSP to suggest autocompletions based on database schema [ ]
- sqlanydb-migrator CLI tool: migration support for database development [ ]
- accompanying feature support in sqlanydb-tools-vscode extension [ ]
- database explorer in sqlanydb-tools-vscode-extension [ ]
There are 2 ways to install the VSCode extension:
- Navigate to the
Extensions
tab in VSCode and search forsqlanydb-tools-vscode
- Download the VSIX file from the Visual Studio Marketplace
- SAP SQL Anywhere 17 You will need to have SAP SQL Anywhere 17 installed on your machine. You can obtain a developer license here
- Create a SAP SQL Anywhere 17 Development Databse
Once you have installed SAP SQL Anywhere 17, open
SQL Central
and in the top bar of the application go toTools > SQL Anwyhere 17 > Create Database...
and follow the prompts - Node.JS (version 22.9.0)
You can check your NodeJS version with the following command:
If you don't have the required version you can install it from the official Node.JS website or use a node version manager like nvm or nvm for windows to manage multiple versions.
node -v
- Turborepo
This project uses turbo to manage and build multiple packages in the monorepo efficiently. You will need to install turborepo globally:
npm install -g turbo
- ts-node
To make it easier to run and test the CLI and packages written in TypeScript, we recommend using ts-node. You will need to install it globally:
npm install -g ts-node
Once you have all the prerequisites installed, follow these steps to get your development environment up and running:
- Clone the repository
git clone https://github.com/Dwarf1er/sqlanydb-tools.git
- Install dependencies
npm install
- Build the project
turbo run build
To run the command-line tools locally, use the following command:
bash ts-node /path/to/clit-tools.ts
For sqlanydb-manager, rename config.example.json
to config.json
and fill it in with the appropriate information considering the database that you created in step 2
of Prerequisites
When working on this project in VSCode you can press F5
to launch the extension in a new Extension Development Host
window
This project is licensed under the MIT License
- A massive shoutout to alexandre-lavoie for rescuing me from the depths of my own misguided "brilliance"! Your help on restructuring this project transformed the chaos into something that actually works.
Check out alexandre-lavoie's awesome projects here!