FlowDiagram
Database & ER modelsMermaid

Two-sided marketplace ER diagram template

Buyers, sellers, listings, orders, reviews, payouts and disputes in Mermaid ER form. This data model has 9 tables and 36 columns, joined by 9 relationships. FlowDiagram draws it as an entity-relationship diagram with crow's-foot notation.

Open in the editor →
  • Free — no account, no trial, no watermark
  • Fully editable shapes and connectors, not a screenshot
  • Export PNG, SVG or PDF, or share it as a link
  • Private: the diagram never leaves your browser

Tables in this data model

  • USER — 4 columns
  • SELLER_PROFILE — 4 columns
  • CATEGORY — 2 columns
  • LISTING — 6 columns
  • LISTING_IMAGE — 3 columns
  • ORDER — 5 columns
  • REVIEW — 4 columns
  • DISPUTE — 4 columns
  • PAYOUT — 4 columns

How to use this ER diagram template

  1. Click Open in the editor. The ER diagram opens on a new page in FlowDiagram — nothing is uploaded and there is no sign-up.
  2. Rename, add or delete shapes and drag them where you want; connectors stay attached as things move.
  3. Drop in vendor logos from the library — 1,160 of them, including every AWS, Azure and Google Cloud service icon — or restyle it with the colour and theme controls.
  4. Prefer text? Edit the Mermaid source below and paste it in through ☰ → Import diagram (see the Mermaid editor); it imports as an editable diagram.
  5. Export to PNG, SVG or PDF, or press Ctrl+L for a link that carries the whole diagram.

Mermaid source

The whole template is the text below. Paste it into FlowDiagram, keep it in Git next to the code it describes, or hand it to an AI assistant to extend.

erDiagram
  USER ||--o| SELLER_PROFILE : "may have"
  SELLER_PROFILE ||--o{ LISTING : publishes
  CATEGORY ||--o{ LISTING : contains
  LISTING ||--o{ LISTING_IMAGE : shows
  USER ||--o{ ORDER : buys
  LISTING ||--o{ ORDER : "sold in"
  ORDER ||--o| REVIEW : "reviewed by"
  ORDER ||--o| DISPUTE : "may raise"
  SELLER_PROFILE ||--o{ PAYOUT : receives
  USER {
    int user_id PK
    string email
    string name
    date joined_on
  }
  SELLER_PROFILE {
    int seller_id PK
    int user_id FK
    string shop_name
    string payout_account
  }
  CATEGORY {
    int category_id PK
    string name
  }
  LISTING {
    int listing_id PK
    int seller_id FK
    int category_id FK
    string title
    decimal price
    string status
  }
  LISTING_IMAGE {
    int image_id PK
    int listing_id FK
    string url
  }
  ORDER {
    int order_id PK
    int buyer_id FK
    int listing_id FK
    decimal amount
    string status
  }
  REVIEW {
    int review_id PK
    int order_id FK
    int rating
    string body
  }
  DISPUTE {
    int dispute_id PK
    int order_id FK
    string reason
    string outcome
  }
  PAYOUT {
    int payout_id PK
    int seller_id FK
    decimal amount
    date paid_on
  }

Related: Database schema diagram tool · Mermaid editor · All database & er models templates · All 521 templates