The evening is all. I am new to SQL, but cheated quite a bit. I follow the manual that I found on the Internet to find out SQLafter 21 days, and I am having trouble figuring out what causes the error.
I am trying to use data INSERTin an existing table. The primary key for this table AddressID. The data I'm trying to enter is in the code below:
INSERT INTO [dbo].[Address]
(AddressID,Street,City,State,ZipCode)
VALUES
(1,'2400 Broadway','New York','NY',11201),
(2,'320 21st Street','Atlanta','GA',303),
(3,'439 Skyline Blvd','Seattle','WA',98101),
(4,'56 Park Avenue','Dallas','TX',75201);
GO
I keep getting this error:
Msg 2627, Level 14, State 1, Line 2 Primary Key Violation Restriction "PK_Address". Unable to insert duplicate key in object 'Dbo.Address. The duplicate key value is (1).
, , . INSERT INTO , VALUES . , INSERT . 4 .
?