Check out example codes for "add primary key to existing table mysql". It will help you in understanding the concepts better.

Code Example 1

CREATE TABLE table_name
   Column1 datatype,		// column1 and datatype
   Column2 datatype,		// column2 and datatype
   Column3 datatype,		// column3 and datatype
   PRIMARY KEY (Column1);	// column1 is the primary key

Code Example 2

# Adding primary key to existing table
ALTER TABLE table_name ADD PRIMARY KEY(primary_key_id)

Learn ReactJs, React Native from