title: Violation of PRIMARY KEY constraint on a column I not set it to be
body: <p>My database is SQL Server. I want to insert a duplicate key in <code>RequestId</code>, then come across this error.</p>
  
  <p><strong>In addition</strong>:My database is created by <code>Visual Studio Sql Server 2008 Server Project</code></p>
  
  <p>I'm sure there is no constraint in the table.</p>
  
  <p>Neither a column is <code>PRIMARY KEY</code>:</p>
  
  <pre><code>CREATE TABLE [dbo].[RequestPrize] (
      [RequestId] INT           NOT NULL,
      [PrizeId]   INT           NULL,
      [Verified]  BIT           NOT NULL,
      [Created]   SMALLDATETIME NOT NULL
  );
  </code></pre>
  
  <p>But when I insert a duplicate key of RequestId:</p>
  
  <pre><code>insert into [RequestPrize] (RequestId, PrizeId) values('138', 9)
  </code></pre>
  
  <p>error output :</p>
  
  <blockquote>
    <p>Violation of PRIMARY KEY constraint 'PK_RequestPrize'. Cannot insert duplicate key in object 'dbo.RequestPrize'.</p>
  </blockquote>
  
  <p>Then I try to drop this constraint,</p>
  
  <pre><code>ALTER TABLE [RequestPrize] DROP CONSTRAINT RequestId
  </code></pre>
  
  <p>error :</p>
  
  <blockquote>
    <p>Msg 3728, Level 16, State 1, Line 1<br>
    'RequestId' is not a constraint.<br>
    Msg 3727, Level 16, State 0, Line 1<br>
    Could not drop constraint. See previous errors.</p>
  </blockquote>
  
  <p><strong>update:</strong>
  I really want to know where this <code>CONSTRAINT</code> come from.</p>