Skip to content
SQLAI.ai

Get the most out of your SAP SQL Anywhere database with AI

Chat with SAP SQL Anywhere using AI, generate schema-aware SQL, optimize queries and validate or explain SQL Anywhere SQL.

Combining frontier AI models with SAP SQL Anywhere, you can move faster and more safely while getting more value from your embedded and server deployments.

Chat with your SAP SQL Anywhere database

SQLAI uses frontier AI models to turn natural-language questions into SQL Anywhere SQL. In a long-running conversation, follow-up questions can refine filters and calculations or explore a question in more detail without starting over. This ensures that you always get exactly what you want and helps you better understand what the generated query does.

SQLAI does not execute generated queries against SQL Anywhere today. Review the SQL in the conversation, then run it in Interactive SQL, dbisql or your application. Result rows are never added to the conversation automatically, but you can include a sample or summary in a follow-up if you want the model to consider it.

Try the Text-to-SQL demo to see a full conversation.

Import a SQL Anywhere schema

A SQL Anywhere schema can be pasted or uploaded as DDL, JSON or CSV, or described to the AI parser as documentation or another schema export. Direct connection is not available for SQL Anywhere. You can also select SQL Anywhere without attaching a schema. The public API engine name is sybase_sql_anywhere; see all supported databases and versions.

The imported schema and optional database rules give the AI context about your tables and relationships, helping it generate accurate, relevant SQL. Rules are a useful place to record the release, whether the database runs as a server or embedded in an application, page-size and compatibility settings, and any materialized-view or synchronization conventions. SQLAI is built for large SQL Anywhere schemas: you don't have to trim your schema or paste it into every prompt, and the AI stays focused on the tables and columns that matter for your question as the schema grows. Learn more about how SQLAI keeps your database context in every chat.

See importing a SQL Anywhere schema in action.

Optimize SQL Anywhere queries

The SQL optimizer reviews slow SQL Anywhere queries and suggests rewrites or indexes intended to reduce execution time while preserving results. It can reason about indexes, join order, materialized views and predicates that prevent index use. SQL Anywhere also exposes optimizer controls such as OPTIMIZATION_GOAL and FORCE OPTIMIZATION; these are useful when you need a stable plan for an embedded deployment.

Optional deep analysis can compare a baseline and proposed rewrite using advanced evaluation matrices. This provides even more accurate optimization suggestions. The rewrite and its performance should still be verified against the production workload.

EXPLAIN shows the chosen plan, and sa_conn_properties plus the server's statistics help explain what the optimizer saw. Because SQL Anywhere is often embedded, the device, cache size and synchronization workload can dominate query performance. See deep analysis in the SQL optimizer on a sample query.

Validate SQL Anywhere queries

The SQL validator performs an in-depth review of potential syntax and semantic issues, including invalid identifiers, type mismatches, ambiguous joins and SQL Anywhere-specific constructs. It explains findings and can suggest corrected SQL. Schema context can help with checking table names and relationships, but validation does not guarantee that a query matches the intended result.

Try the SQL validator on a query of your own.

Explain SQL Anywhere queries

The SQL explainer breaks down an existing query, including its joins, filters, aggregations, materialized-view rewrites and returned columns. Follow-up questions can focus on a particular clause, an optimizer setting or potential edge case.

Try the SQL explainer on a query you want to understand.

Share SQL Anywhere schemas and threads

An imported SQL Anywhere database can be shared with teammates, who can use its schema and rules in their own chats. Only the owner can edit the database configuration. There is no live SQL Anywhere connection to share today, so teammates work from the shared schema rather than a live database.

Chat threads can be shared by invitation or link as read-only transcripts. Recipients can review the conversation, but only the owner can continue it. Query result rows are not saved in the thread.

Frequently asked questions

Do I need a live SQL Anywhere connection to use SQLAI?

No, and direct connections are not available for SQL Anywhere today. Import the schema by pasting or uploading DDL, JSON or CSV, or let AI parse a description of your schema. You can also select SQL Anywhere without attaching a schema.

Does SQLAI run queries against my database automatically?

No. SQLAI does not execute generated queries against SQL Anywhere today. Generated SQL is for you to review and run in Interactive SQL, dbisql or your application. Result rows are not added to a chat thread automatically.

Can SQLAI handle large SQL Anywhere schemas?

Yes. SQLAI is designed for large schemas with many tables and relationships. You can keep your whole schema imported, and responses stay focused on the tables and columns that matter as it grows. Learn more about how SQLAI keeps your database context in every chat.

Which SQL Anywhere versions are supported?

There is no version picker for SQL Anywhere, so the supported databases page lists the engine as covering all versions. Add the release, server-versus-embedded mode and page-size settings to the database rules so generated SQL matches your deployment.

Is SQL Anywhere the same as Sybase ASE?

No. SQL Anywhere and Sybase ASE are different database products with different SQL dialects, catalogs and administration. Select sybase_sql_anywhere for SQL Anywhere and sybase for ASE so the AI does not mix their syntax.

Review before production

AI-generated SQL queries can contain errors. Queries should be reviewed and their results and performance tested in a copy of the target SQL Anywhere database before production use. Check the plan, cache size, page size and synchronization behavior on representative devices or servers.