Database Generation
Database output depends on the export path you choose. A Database Schema export produces DDL and table structure SQL for the selected database type, while Martini package generation can also include CRUD SQL logic inside the generated services and workflows.
Supported Databases
| Database | Notes |
|---|---|
| PostgreSQL | Full ANSI + PostgreSQL-specific syntax |
| MySQL | Full ANSI + MySQL-specific syntax |
| HSQL | Suitable for development and testing |
| MSSQL (SQL Server) | Full ANSI + MSSQL-specific syntax |
| Oracle | Full ANSI + Oracle-specific syntax |
Negroni uses ANSI query language as a base, with database-specific syntax applied for operations such as auto-increment, limit/offset, and DDL statements.
What Gets Generated
Database Schema Export
Database Schema export generates the database structure for the selected manifest. This includes table definitions and database-specific DDL.
Martini Package Services and Workflows
When you generate a Martini package with database-backed services, Negroni can include CRUD SQL logic for the generated service operations.
Primary Keys (Auto-Increment)
Negroni generates a primary key for each entity using the appropriate auto-increment mechanism for the selected database. This eliminates the need to implement custom identifier generation.
Coalesce on Update
The generated UPDATE query uses a Coalesce pattern: if a field is null in the update payload, the existing stored value is retained rather than overwritten. This prevents unintentional data loss during partial updates.
Limit and Offset
The Get All query supports limit and offset pagination out of the box, improving performance when working with large datasets.
Join Queries
For entities with defined relationships, Negroni generates JOIN queries automatically. This allows related data to be fetched in a single query — for example, retrieving all orders for a specific customer.
Configuring the Database
Database settings are configured in the manifest's SQL configuration tab:
- Right-click the manifest and select
Configure.
- Open the
SQL tab.
- Set the connection pool details.
- Select the query configuration type.
- Click
Save.