erDiagram
CUSTOMER ||--o{ ORDER : places
ORDER ||--|{ LINE-ITEM : contains
CUSTOMER }|..|{ DELIVERY-ADDRESS : uses
CUSTOMER {
string name
string email
}
ORDER {
int id
date placed
}Syntax
A ||--o{ B : labelrelates two entities; each end's pair of marks is its cardinality —|ozero or one,||exactly one,}ozero or more,}|one or more.--is an identifying relationship,..a non-identifying one.ENTITY { type name }lists attributes;PK,FKandUKafter one mark keys, and a quoted string comments it.