INSERT function

Viewed 37

I am trying to insert values into DB, but I am getting an Error. When I add them one by one they work but if I want to add all of them this is the error I am getting:

ERROR: duplicate key value violates unique constraint "blse_pkey" DETAIL: Key (date, employment_1000s, industry, state)=(2020-01-31, 2082.7, Total Nonfarm , Alabama) already exists. SQL state: 23505

This is the script I am using.

INSERT INTO blse VALUES('2020-01-31',436.5,'Government','Missouri'); 
INSERT INTO blse VALUES('2020-01-31',488.6,'Total Nonfarm','Montana'); 
0 Answers
Related