Schemas

Create a schema

The Create Schema wizard names your schema, sets the SQL dialect it targets, and gives you five ways to fill it. Three of those paths do their work in the background and hand you a review screen or a progress view.

In the app: Data Model › Schemas › Create Schema

[screenshot]
The Create New Schema wizard on the "How do you want to build it?" step, showing the five starting-point cards.

Before you start

  • You need Read/Write access in the organization. The Create Schema button is disabled while the organization is in read-only mode.
  • The connection path needs at least one saved database connection.
  • The duplicate path needs at least one existing schema.

Step 1: name the schema and choose a dialect

  1. On the Schemas page, click Create Schema. The Create New Schema wizard opens on Schema Identity.
  2. Enter a Schema Name. It is required, up to 256 characters, and must be unique in your organization. If the name is taken, the wizard shows A schema with this name already exists.
  3. Pick a Database System. This is the SQL dialect the schema generates for. Each option has a one-line description. See Supported database targets.
  4. Optionally click one or more Labels to attach them. If your organization has none, the wizard says so; see Organization labels.
  5. Click Next.

Tip: The name and labels are easy to change later. The dialect matters more, because it drives everything the schema generates. You can change it later on the Settings tab, but existing SQL bodies are not rewritten.

Step 2: pick a starting point

The How do you want to build it? step shows five cards. Pick one and click Next.

Card What it does
Start from blank Creates an empty schema you fill in yourself.
Create from a script Uploads a SQL DDL, YAML, JSON or text file and parses it in the background.
Import from a database connection Reads a live database through a saved connection. You review the changes before anything is written.
Duplicate an Existing Schema Copies another schema’s tables, views and code into this one, converted to the dialect you picked.
Start from a sample Loads a ready-made online-retail schema.

A card is greyed out when its path can’t run. The connection card needs a saved connection, the duplicate card needs an existing schema, and the sample card is unavailable in read-only mode.

Start from blank

The wizard shows a summary of the name, dialect and labels. Click Create schema. The schema is created with no tables.

Create from a script

  1. Drop a file on the upload zone or click to browse. The wizard accepts .sql, .yaml, .yml, .json and .txt files up to 5 MB.
  2. Click Create and import.

The schema is created straight away and the import runs in the background. It creates tables, indexes, foreign keys, views, stored procedures and functions in dependency order. To paste a script instead of uploading a file, create a blank schema and use Import Database Objects From Script on its Info tab. See Start an import.

Import from a database connection

  1. Pick a Connection.
  2. Optionally fill in Include schemas (optional) with comma-separated source schema names, for example dbo, sales. Leave it blank to read every schema the connection can see.
  3. Click Create and connect.

Kenseme creates the schema and starts reading the source catalog. Nothing is written to your schema until you review and apply the proposed changes. See Import objects from a database connection.

Duplicate an existing schema

  1. Pick the Source schema. The wizard shows the target dialect you chose in step 1 (Will be created as …).
  2. Read the preflight: how many code objects and expressions will be AI-converted, and any column type warnings. Click the warning line to see the affected columns.
  3. Click Duplicate Schema.

The source and target dialects must differ. If they match, the wizard asks you to go back and change one. Pipelines and star-schema plans are not copied. See Clone a schema to another dialect.

Start from a sample

The wizard shows what you’ll get: 34 tables · 8 views · 6 stored procedures. Click Create sample schema. The sample is always created for SQL Server, whatever dialect you picked. See Try Kenseme with the sample retail schema.

What happens next

The wizard ends on a Schema created step that says what happened. Its button depends on the path:

Path Button Where it takes you
Blank, sample View schema The schema workspace.
Script View schema The schema workspace. The import keeps running in the background.
Connection Review changes The Review database objects page.
Duplicate Review changes The Review converted SQL page.

If the schema was created but its import could not start, the wizard says so and offers View schema. You can start the import again from the schema’s Info tab.