SQL Server, PostgreSQL, and MySQL — platform-specific conventions, naming rules, and connection setup.
By the SchemaSmith Team · Last reviewed
Ask Forge speaks SQL Server, PostgreSQL, and MySQL fluently.
Ask Forge supports three database platforms. Each platform has its own provider that generates platform-specific SQL, applies naming conventions, and handles platform capabilities.
| Feature | SQL Server | PostgreSQL | MySQL |
|---|---|---|---|
| Platform ID | SqlServer |
PostgreSQL |
MySQL |
| Default Schema | dbo |
public |
None (database-level) |
| Max Identifier Length | 128 | 63 | 64 |
| Identifier Wrapping | [Name] |
"name" |
`Name` |
| Naming Convention | PascalCase | snake_case (lowercase preferred) | PascalCase |
| Identity Syntax | IDENTITY(1,1) |
GENERATED ALWAYS AS IDENTITY |
AUTO_INCREMENT |
| Schemas | |||
| Temporal Tables | |||
| Enum Types | |||
| Domain Types | |||
| Array Types | |||
| JSON Columns | |||
| Computed Columns | |||
| Partitioning | |||
| Full-Text Search | |||
| XML Indexes |
Each platform uses its own set of naming prefixes for database objects. Ask Forge applies these automatically when generating SQL.
| Object | Prefix |
|---|---|
| Table | (none) |
| View | vw_ |
| Stored Procedure | usp_ |
| Function | fn_ |
| Index | IX_ |
| Foreign Key | FK_ |
| Primary Key | PK_ |
| Unique Constraint | UQ_ |
| Check Constraint | CK_ |
| Default Constraint | DF_ |
| Object | Prefix |
|---|---|
| Table | (none) |
| View | v_ |
| Stored Procedure | (none) |
| Function | fn_ |
| Index | ix_ |
| Foreign Key | fk_ |
| Primary Key | pk_ |
| Unique Constraint | uq_ |
| Check Constraint | ck_ |
| Default Constraint | df_ |
| Object | Prefix |
|---|---|
| Table | (none) |
| View | vw_ |
| Stored Procedure | usp_ |
| Function | fn_ |
| Index | IX_ |
| Foreign Key | FK_ |
| Primary Key | PK_ |
| Unique Constraint | UQ_ |
| Check Constraint | CK_ |
| Default Constraint | DF_ |
lower_case_table_names=0), making schemas non-portable across operating systems.
Ask Forge derives the active platform from the schema product you are working in — there is no global platform flag. It resolves the platform in this order:
Product.json when you open a product with --product, or when you run inside a product directory (Ask Forge walks up from the current folder to find it).~/.schemasmith/session.json on startup.SqlServer if nothing else is set.Tools that target a specific platform accept a --platform parameter (sqlserver, postgresql, mysql). For example, to inspect a platform's features, naming rules, and identifier limits:
ask-forge show-platform-capabilities --platform postgresql
ForgeBarrett:Platforms:Default configuration key (default SqlServer).
Configure database connections with the manage-connection command (action set). Each platform has its own default port and connection parameters.
ask-forge manage-connection --action set \
--platform sqlserver --server localhost --port 1433 \
--database MyDB --user sa --password "..."
ask-forge manage-connection --action set \
--platform postgresql --server localhost --port 5432 \
--database mydb --user postgres --password "..."
ask-forge manage-connection --action set \
--platform mysql --server localhost --port 3306 \
--database mydb --user root --password "..."