Violation of PRIMARY KEY constraint ...

Results 1 to 3 of 3

Thread: Violation of PRIMARY KEY constraint ...

  1. #1
    Join Date
    Dec 1969
    Posts
    1,671

    Default Violation of PRIMARY KEY constraint ...

    I&#039ve looked all over and can&#039t seem to find any real or practical solutions. I&#039m not sure why this happened, the application worked fine for the first day and now it&#039s hosed. I&#039m being led to believe that the SQL server was not shut down correctly and the indexes are corrupt for these tables. It seems to be the whole database is doing it now. Help!!!<BR>Thanks in advance.

  2. #2
    Shawn Clabough Guest

    Default RE: Violation of PRIMARY KEY constraint ...

    Which database are you using? Is the primary key an autonumber field? If this is SQL server, try issuing the command "DBCC CHECKIDENT (&#060;table name&#062;)" from the SQL manager query builder window.

  3. #3
    Join Date
    Dec 1969
    Posts
    1,671

    Default RE: Violation of PRIMARY KEY constraint ...

    Thanks!<BR>I run this against all of the tables and everything is fine.<BR>I&#039m sure I will use this later<BR>Thanks again,<BR>Mike

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •