Aqua Data Studio version 25.0 introduces AI Assist, an advanced Artificial Intelligence (AI) feature designed to streamline query development. Users can now ask questions in natural language, and AI Assist will generate SQL queries based on session-specific pre-prompt information and metadata. These queries can be executed directly in the Query Analyzer window, allowing users to see and use Aqua Data Studio’s result set tools seamlessly.

AI Assist is accessible to both standard and ultimate licensed users.

Aqua Data Studio adds a Multi-AI framework with a unified interface to integrate OpenAI. The framework aims to provide a secure API, with AI engine specifications, and ensure efficient prompt management and session handling.

The new feature focuses on OpenAI Interface to include AI interaction, process natural language queries, and handle responses.

It defines response formats, such as SQL and Text responses, based on predefined prompts. 

MongoDB and variations are not supported in v25.0.

AI Assist in Aqua Data Studio is available by default when you install v25.0.

To access its properties, navigate to the main menu and select File > Options, then choose AI Configuration. These options are required to enable and use the AI Assist function.

AI Assist configuration properties include:

Enable AI: Default selection to have the feature available.
Engine: Default Open AI is available.
Model: Select AI Model to be used, GPT-3.5 Turbo, GPT-4o or GPT-4o mini.
API Key: Create and export an API key from OpenAI.
Format AI Generated SQL: Automatically format SQL scripts generated by AI Assist.
Log all AI Conversation: Messages from AI Assist are logged.

AI Assist Chat Window

The AI Chat Window enables seamless communication with AI using natural language. This feature is designed to enhance user interaction and streamline workflows. Below are the key features and functionalities:

  • AI Communication: Users can interact with AI in a chat window that displays the AI’s responses in a structured and user-friendly format.
  • Response Presentation: AI outputs, including text, syntax-highlighted SQL queries, and scrollable tables, are displayed.
  • Session Logging: The chat window acts as a historical log for all communications with AI during the current session.
    • If the Query Analyzer session is closed, the chat log is discarded.
    • If Aqua Data Studio is closed with the Query Analyzer window still open, the chat log will persist and reappear upon restarting Aqua Data Studio.

If AI Assist is configured, meaning the AI properties are filled out with a valid OpenAI key, then the window will be available and ready to receive queries on the right side of the window.

If it’s not connected to a Database, the AI Assist window will not be enabled and it will be grayed out.

Toolbar in AI Assist

The Toolbar options for AI Assist include:

 Share Database Metadata: When using Query Analyzer, you can access the database structure you are connected to, allowing you to explore its schema and configuration. This helps share information about the structure, schema, or configuration of a database without exposing the actual data stored.

Set Message Limits: Allows users to define restrictions on the Conversation Limit and History Limit. The Conversation Limit sets the maximum number of previous messages included in the context when sending queries to the AI engine, affecting response time and cost. The History Limit determines the maximum number of messages retained in the AI Assist chat session, with older messages being removed once the limit is exceeded.

Settings: Takes you to the AI configuration under Options.

Delete All Messages: To delete all messages displayed.

If you want to delete messages or add metadata, you’ll need to reload the metadata when loading tables. If you later need to add another table, you’ll have to reload the metadata, previously selected, add the new table, and select all the Objects again.

In the Settings icon, on the top right side of the AI Assist window, you can select different ways to view the window. Check our Panels page for more information on each view.

AI Integration in Query Analyzer

  • Natural Language to SQL: Users can input a natural language query as a comment in the Query Analyzer window and generate corresponding SQL. To do this, users need to highlight the comment and click the "Generate SQL with AI" icon.
  • AI Chat Window: Each Query Analyzer window is paired with a single AI chat window. Queries pushed to the Query Analyzer window are processed like any other query, allowing users to utilize the standard tools alongside AI features. The AI window maintains a rolling history of AI requested queries from the QA window.
  • Highlight and Override: Highlighting a query in the Query Analyzer window enables the AI chat window to override its content. 
  • Simplified AI Responses: AI responses are filtered to include only the SQL suggestions, removing additional comments.
  • Generate SQL with AI: Allows for metadata injection into the pre-prompt.
  • Multi-Language Support: Supports requests and responses in multiple languages.

Here's an example of how you can use the AI Assist chat window and the AI integration within Query Analyzer, connecting to a MySQL database.

  1. Select the Database you want to use with Query Analyzer.

  2. Once connected, the AI Assist is available on the right side of the screen, click on the Share Database Metadata icon, on the left side of the toolbar.

  3. The 'DB Metadata Generator for AI' window will appear, allowing you to select the tables you want to include when generating a query wand click Next.

  4. Review the DDL for the tables selected and click Apply.

  5. Now you are ready to start using natural language AI Assistant and create SQL queries. AI is able to recognize a good range of queries, from the easiest to the most complex queries.

  6. Describe the query you need from the shared database metadata to get SQL queries.

  7. You can use the copy icon on the right side of the AI response to highlight and copy/paste or drag and drop the query to run it.

  8. You can also do a reverse query, type your query in the Query Analyzer environment and click the "Generate SQL with AI" icon on the right side of the Query Analyzer toolbar.
    The query will automatically be copied to the AI Assist chat window, it will generate the response and it will give you the query you requested, automatically copying it to the Query Analyzer environment, so you don’t need to copy/paste again.


    When the AI Assist window generates a SQL statement, you can easily move it to the Query Analyzer window using drag-and-drop. Simply highlight the SQL statement and drag it over, or use the cut/paste icon to move it. This allows you to quickly transfer and execute the generated SQL without manually copying and pasting.


  • No labels