Primary Key - ERDL Diagram Syntax

  • Type PK to mark a field as primary key
  • To define a composite primary key, use the table level PK() syntax
Customer
-
CustomerID int PK
Name varchar(100)
Address1 string
Address2 string
City string

(or)

Customer
-
CustomerID int
Name varchar(100)
Address1 string
Address2 string
City string
PK(CustomerID, Name)