SAP SQL Anywhere SQL Parser Support in GSP¶
This page documents the SQL syntax support for SAP SQL Anywhere in the General SQL Parser.
SAP SQL Anywhere. SQL Anywhere selects Watcom-SQL or Transact-SQL per statement, and this vendor accepts both — while rejecting Sybase ASE-only statements (such as DUMP TRANSACTION) and Sybase IQ-only DDL. For scripts mixing the historical Sybase family, use the permissive sybase vendor.
Syntax Coverage Corpus¶
GSP tests SAP SQL Anywhere syntax against 119 documented constructs grouped into 77 categories, each cross-referenced to the documentation that defines it (4 distinct source pages).
Parse coverage¶
Measured against GSP Java 4.2.6 on 2026-08-18 (UTC) (artifact sha256 44c4c247d5ee). Each construct below carries the complete set of examples from the SAP SQL Anywhere documentation; a construct counts as fully covered only when every one of its examples parses. Percentages are pass rates over this documented-example corpus — not a percentage of the entire SQL dialect.
| Constructs fully parsed | Individual statements parsed | |
|---|---|---|
| All constructs | 108 of 119 (91%) | 291 of 328 (89%) |
| SELECT (queries) | 8 of 8 (100%) | 15 of 15 (100%) |
| DML (INSERT / UPDATE / DELETE / MERGE) | 5 of 5 (100%) | 16 of 16 (100%) |
| Stored procedures | 0 of 3 (0%) | 4 of 8 (50%) |
Statements are split using the parser's own statement splitter, so multi-statement examples and procedure bodies are counted correctly. The SELECT, DML and stored-procedure rows classify each statement by its parsed statement type: a construct is counted in a row when its examples contain at least one statement of that class, and is fully parsed when all of them parse. Stored procedures covers CREATE PROCEDURE / FUNCTION / PACKAGE / TRIGGER definitions and anonymous blocks.
Machine-readable: dialect data (JSON) · all-dialect matrix · coverage matrix overview
All 119 constructs¶
| Construct | Category | Parses | Specified in |
|---|---|---|---|
ALLOCATE DESCRIPTOR |
ALLOCATE DESCRIPTOR | all 1 | third-party reference |
ALTER DATABASE |
ALTER | all 3 | third-party reference |
ALTER DBSPACE |
ALTER | all 6 | third-party reference |
ALTER DOMAIN |
ALTER | all 1 | third-party reference |
ALTER EVENT |
ALTER | all 1 | third-party reference |
ALTER FUNCTION |
ALTER | all 1 | third-party reference |
ALTER INDEX |
ALTER | all 4 | third-party reference |
ALTER LOGIN POLICY |
ALTER | all 1 | third-party reference |
ALTER PROCEDURE |
ALTER | all 1 | third-party reference |
ALTER SERVER |
ALTER | all 4 | third-party reference |
ALTER SERVICE |
ALTER | all 2 | third-party reference |
ALTER TABLE |
ALTER | all 17 | third-party reference |
ALTER USER |
ALTER | all 1 | third-party reference |
ALTER VIEW |
ALTER | all 1 | third-party reference |
BACKUP |
BACKUP | all 4 | third-party reference |
BEGIN TRANSACTION |
BEGIN TRANSACTION | all 1 | third-party reference |
BEGIN … END |
BEGIN … END | 1 of 4 | third-party reference |
CALL |
CALL | all 2 | third-party reference |
CASE |
CASE | 5 of 7 | third-party reference |
CHECKPOINT |
CHECKPOINT | all 1 | third-party reference |
CLEAR |
CLEAR | all 1 | third-party reference |
CLOSE |
CLOSE | all 3 | third-party reference |
COMMENT |
COMMENT | all 2 | third-party reference |
COMMIT |
COMMIT | all 1 | third-party reference |
CONFIGURE |
CONFIGURE | all 1 | third-party reference |
CONNECT |
CONNECT | all 7 | — |
CREATE DATABASE |
CREATE | all 6 | third-party reference |
CREATE DBSPACE |
CREATE | all 5 | third-party reference |
CREATE DOMAIN |
CREATE | all 1 | third-party reference |
CREATE EVENT |
CREATE | 9 of 12 | third-party reference |
CREATE EXISTING TABLE |
CREATE | all 1 | third-party reference |
CREATE EXTERNLOGIN |
CREATE | all 1 | third-party reference |
CREATE FUNCTION |
CREATE | 1 of 3 | third-party reference |
CREATE INDEX |
CREATE | all 5 | SAP SQL Anywhere reference, CREATE INDEX statement (rebuilt 2026-08-16; the previous file was sourced from the Sybase IQ reference and carried IQ-only index types — see PROVENANCE.md) |
CREATE LOGIN POLICY |
CREATE | all 1 | third-party reference |
CREATE MESSAGE |
CREATE | all 1 | third-party reference |
CREATE PROCEDURE |
CREATE | 3 of 5 | third-party reference |
CREATE SCHEMA |
CREATE | all 1 | third-party reference |
CREATE SERVER |
CREATE | all 3 | third-party reference |
CREATE SERVICE |
CREATE | all 2 | third-party reference |
CREATE TABLE |
CREATE | all 18 | — |
CREATE USER |
CREATE | all 3 | third-party reference |
CREATE VARIABLE |
CREATE | all 1 | third-party reference |
CREATE VIEW |
CREATE | all 2 | third-party reference |
DEALLOCATE DESCRIPTOR |
DEALLOCATE DESCRIPTOR | all 1 | third-party reference |
Declaration section |
Declaration section | 0 of 6 | — |
DECLARE |
DECLARE | all 1 | third-party reference |
DECLARE CURSOR |
DECLARE CURSOR | all 4 | third-party reference |
DECLARE LOCAL TEMPORARY TABLE |
DECLARE LOCAL TEMPORARY TABLE | all 3 | third-party reference |
DELETE |
DELETE | all 3 | third-party reference |
DESCRIBE |
DESCRIBE | all 1 | third-party reference |
DISCONNECT |
DISCONNECT | all 1 | third-party reference |
DROP |
DROP | all 2 | third-party reference |
DROP CONNECTION |
DROP | all 1 | third-party reference |
DROP DATABASE |
DROP | all 3 | third-party reference |
DROP EXTERNLOGIN |
DROP | all 1 | third-party reference |
DROP LOGIN POLICY |
DROP | all 1 | third-party reference |
DROP SERVER |
DROP | all 1 | third-party reference |
DROP SERVICE |
DROP | all 1 | third-party reference |
DROP STATEMENT |
DROP | all 2 | third-party reference |
DROP USER |
DROP | all 1 | third-party reference |
DROP VARIABLE |
DROP | all 1 | third-party reference |
EXECUTE |
EXECUTE | all 4 | third-party reference |
EXECUTE IMMEDIATE |
EXECUTE IMMEDIATE | all 1 | third-party reference |
EXIT |
EXIT | all 1 | third-party reference |
FETCH |
FETCH | all 1 | third-party reference |
FOR |
FOR | 2 of 4 | third-party reference |
FORWARD TO |
FORWARD TO | all 4 | third-party reference |
FROM |
FROM | all 1 | third-party reference |
GET DESCRIPTOR |
GET DESCRIPTOR | all 1 | third-party reference |
GOTO |
GOTO | all 6 | third-party reference |
GRANT |
GRANT | all 5 | third-party reference |
IF |
IF | 2 of 12 | third-party reference |
INCLUDE |
INCLUDE | all 1 | third-party reference |
INSERT |
INSERT | all 3 | third-party reference |
INSTALL JAVA |
INSTALL JAVA | all 2 | third-party reference |
LEAVE |
LEAVE | 1 of 2 | third-party reference |
LOAD TABLE |
LOAD TABLE | all 7 | third-party reference |
LOCK TABLE |
LOCK TABLE | all 2 | third-party reference |
LOOP |
LOOP | 3 of 7 | third-party reference |
MESSAGE |
MESSAGE | all 3 | third-party reference |
OPEN |
OPEN | all 2 | third-party reference |
OUTPUT |
OUTPUT | all 2 | third-party reference |
PARAMETERS |
PARAMETERS | all 1 | third-party reference |
PREPARE |
PREPARE | all 1 | third-party reference |
PRINT |
all 2 | third-party reference | |
PUT |
PUT | all 1 | third-party reference |
RAISERROR |
RAISERROR | all 1 | third-party reference |
READ |
READ | all 2 | third-party reference |
RELEASE SAVEPOINT |
RELEASE SAVEPOINT | all 1 | third-party reference |
REMOVE |
REMOVE | all 1 | third-party reference |
RESIGNAL |
RESIGNAL | all 1 | third-party reference |
RESTORE |
RESTORE | all 4 | third-party reference |
RESUME |
RESUME | all 1 | third-party reference |
RETURN |
RETURN | all 1 | third-party reference |
REVOKE |
REVOKE | all 8 | third-party reference |
ROLLBACK |
ROLLBACK | all 2 | third-party reference |
ROLLBACK TO SAVEPOINT |
ROLLBACK TO SAVEPOINT | all 1 | third-party reference |
SAVEPOINT |
SAVEPOINT | all 1 | third-party reference |
SELECT |
SELECT | all 6 | third-party reference |
SET |
SET | all 2 | third-party reference |
SET CONNECTION |
SET | all 2 | third-party reference |
SET DESCRIPTOR |
SET | all 1 | third-party reference |
SET OPTION |
SET | all 4 | third-party reference |
SET SQLCA |
SET | all 1 | third-party reference |
SIGNAL |
SIGNAL | all 1 | third-party reference |
START DATABASE |
START DATABASE | all 2 | third-party reference |
START ENGINE |
START ENGINE | all 2 | third-party reference |
START JAVA |
START JAVA | all 1 | third-party reference |
STOP DATABASE |
STOP DATABASE | all 1 | third-party reference |
STOP ENGINE |
STOP ENGINE | all 1 | third-party reference |
STOP JAVA |
STOP JAVA | all 1 | third-party reference |
TRIGGER EVENT |
TRIGGER EVENT | all 1 | third-party reference |
TRUNCATE TABLE |
TRUNCATE | all 1 | third-party reference |
UNION |
UNION | all 1 | third-party reference |
UPDATE |
UPDATE | all 8 | third-party reference |
WAITFOR |
WAITFOR | all 3 | third-party reference |
WHENEVER |
WHENEVER | 3 of 5 | third-party reference |
WHILE |
WHILE | all 1 | third-party reference |