Crow’s foot notation
Crow’s foot is the notation almost every database tool draws: tables as boxes, relationships as lines, and cardinality as marks on the line ends — the three-pronged “foot” that means many gives the notation its name. Two rules read all of it, and every figure below is drawn by ErdDocs rather than pasted in as a picture, so you can redraw from real DDL.
How do you read crow’s foot notation?
- Rule 1 — position. Each line end stacks up to two marks. The mark closest to the table is the maximum (bar = one, crow’s foot = many); the outer mark is the minimum (bar = one, circle = zero) — so a circle followed by a crow’s foot reads “zero or many”, and two bars read “exactly one”.
- Rule 2 — direction. Read a crow’s-foot line twice, once toward each table: the marks at a table’s end say how many of its rows a single row of the other table can have.
Worked example 1: one-to-many
In the schema this line is one column: orders.customer_id NOT NULL REFERENCES customers(id). The NOT NULL is what makes the customer side “exactly one” — drop it and the outer bar becomes a circle, because an order could then exist with no customer.
Worked example 2: one-to-one
The giveaway in DDL: the foreign key is also the primary key — customer_id bigint PRIMARY KEY REFERENCES customers(id). A key that is unique cannot repeat, so the “many” collapses to “one”. Tools that miss this draw a one-to-many here, and the diagram quietly overstates the schema.
Worked example 3: many-to-many
order_items.The junction table’s composite primary key (order_id, product_id) is what enforces “each product at most once per order”. Its extra columns ( qty, unit_price) are the payload a pure many-to-many line has nowhere to put — which is why the junction is drawn, not hidden.
Why is crow’s foot the default ER notation?
Chen notation draws attributes as ovals and relationships as diamonds — expressive on a whiteboard, enormous on a real schema: a 40-table database becomes hundreds of shapes. Crow’s foot collapses each table into one box with its columns inside, which is the shape a schema browser, a migration diff and a code review all need. That economy made it the default in nearly every mainstream database tool — the ER diagram symbols reference sets it next to Chen and UML — while textbooks still teach Chen, because they are optimizing for lectures, not for dumps.
Draw it from your schema
The three examples above come from the schema below — paste it, or your own pg_dump --schema-only /mysqldump --no-data dump. ErdDocs draws the maximum mark on each end — the foot for many, a dash for one — and names the full cardinality on a plate when you select a line; the minimum is the part you read from NOT NULL in the DDL itself. Parsing runs in your browser; the schema never leaves your device.
FAQ
What does the circle mean in crow’s foot notation?
Zero — the relationship is optional on that side. A circle next to a crow’s foot reads “zero or many”; a circle next to a bar reads “zero or one”. Its opposite is a bar in the outer position: “at least one”, meaning the row cannot exist without a partner on the other end.
Is crow’s foot the same as IE notation?
Yes. The notation popularized by Gordon Everest and used in Information Engineering (IE) methods is what everyone calls crow’s foot today. Tools sometimes label the same marks “IE notation” — the symbols and reading rules are identical.
How do I write crow’s foot in text — Mermaid or DBML?
Mermaid erDiagram spells each end with glyphs: ||--o{ reads “exactly one to zero-or-many”. DBML writes relations with < > and - operators instead, and its Ref: syntax carries the same information. Paste either format into ErdDocs and it draws the corresponding crow’s foot line straight from the text.
Why is many-to-many drawn as two one-to-many lines?
Because a relational database cannot store a many-to-many directly — it needs a junction table (order_items between orders and products). ErdDocs, like any tool that reads a real schema, draws the junction table with a one-to-many line to each side — including the join tables Prisma and TypeORM generate but never spell out. A single many-to-many line only appears in conceptual diagrams, where the junction has not been designed yet.
Related
- ER diagram — the whole picture these marks belong to, with a generator for your own schema.
- ER diagram symbols — crow’s foot next to Chen and UML, symbol by symbol.
- ER diagram cardinality — how the marks are determined from keys and constraints.
- Mermaid ER diagrams — the same notation written as text.