Start here

Try Kenseme with the sample retail schema

The sample retail schema is a ready-made online-retail data model with 34 tables, 8 views and 6 stored procedures. Load it to browse tables, follow relationships, generate SQL and try the designers without building anything first.

In the app: Home › Load sample data, or Data Model › Schemas › Create SchemaStart from a sample

[screenshot]
The Sample Retail schema open on the Tables tab.

Note: The sample contains structure only. It has no data rows. Kenseme models tables, columns, keys, relationships, views and procedures; it does not store the contents of tables. Querying the sample returns nothing because there is nothing in it.

Before you start

Loading the sample needs Read/Write access, and it is unavailable while your organization is in read-only mode.

Load the sample

There are three ways in. All of them create the same schema.

  • Home, Finish setting up panel. On a new organization, the Home page shows a Finish setting up panel. Under the import-a-schema step, click or load sample data.
  • Home, Schemas tile. While your organization has no schemas, the Schemas tile shows Load sample data.
  • Create Schema wizard. Click Create Schema, enter a name, choose Start from a sample, then click Create sample schema. See Create a schema.

Loading is immediate. There is no background job and no AI involved. When it finishes, Kenseme tells you how many tables, columns, relationships, indexes and SQL objects it created.

Name, dialect and label

  • Name. From Home, the schema is called Sample Retail. If that name is taken, Kenseme uses Sample Retail 2, Sample Retail 3 and so on, so loading it again never overwrites anything. From the wizard, Kenseme uses the name you typed in step 1, and refuses it if a schema already has that name.
  • Dialect. The sample is always created for SQL Server, even if you picked another dialect in the wizard. Tables and columns generate DDL for any supported target, but the view and procedure bodies are written in T-SQL.
  • Database schema. Objects sit in the retail database schema.
  • Label. The schema gets a Sample label so you can spot it in the schema list.

Want it in another dialect?

Load the sample, then clone it to another dialect. The clone converts the view and procedure bodies for the target dialect.

A short tour of the model

  • Product and variant. Product holds the sellable item; ProductVariant holds each buyable variation such as size or colour. Prices, inventory and order lines hang off the variant.
  • Effective-dated prices. ProductPrice stores prices with validity dates, so a variant has a current price and a history. The vw_CurrentProductPrice view resolves the price in effect.
  • Orders and shipments. An order (OrderOrderLine) can ship in more than one shipment, and ShipmentLine links shipment lines back to order lines. That is how partial and split shipments are modelled.
  • Reference tables. Small lookup tables such as Country, Currency, OrderStatus, PaymentStatus, ShipmentStatus and ReturnReason keep status and locale values consistent.
  • Views and procedures. Views such as vw_ProductCatalog, vw_InventoryAvailability, vw_CustomerOrderHistory, vw_InvoiceAging and vw_CustomerLifetimeValue, and procedures such as usp_PlaceOrder, usp_ApplyPromotion, usp_GenerateInvoice, usp_RecordPayment, usp_ProcessReturn and usp_RecalculateInventory, show how code objects look in the workspace, with output columns and parameters filled in.

Tip: Open the Diagram tab to see the whole model at once, then focus on Order with Hops set to 1.

Afterwards

The sample is an ordinary schema. Browse it, edit it, generate SQL from it, design a star schema over it, or bind an ontology to it. Delete it like any other schema when you’re done. If you loaded it more than once, delete the extra copies.