SQL Newbie - warning message

  • I'm in the process of moving over from Ms2000 to SQL, I'm using a ms adp as my front end. What my problem is that I've got a table called sessions and this as a PK but this allows duplicates. When i run a sproc in a form it works but i get a ms warning box "Duplicate Key was Ignored" with an OK button. Is there anyway to stop this I've tried docmd.setwarning false but it does not do anything, unless i'm putting it in the wrong place. Also because I'm new to SQL is there anything you can put in the sproc to stop the warning message.

    Hope someone can help a new SQL convert.

  • There's no easy way around this, basically what sql server is telling you is that the insert was rolled back because the primary is already in the table (the PK must be unique, there's just no way around that).

    Can you post the table definition of the table so we have a look?

  • Can you remove the PK constraint before moving data ?! Though you'll have some analysis to do on that table once the data is moved to identify a PK...maybe there're other fields in that table that'd serve as better candidates ?!?!







    **ASCII stupid question, get a stupid ANSI !!!**

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply