bcp question, Urgent!

  • Hi All,

    I'm populating a table with let say one set of records. Then I am populating the same table with another set of records. Problem is when I do the second set of records there is some data that is already in my first set. So now the second set data is not pushed over because of the PK constraint error. Is there is a switch I could use so that the bcp utility would run without this interuption ignoring the duplicate row?

    Any thoughts will help!

    Thanks!

  • Try this switch

    /m maxerrors Maximum number of errors that can occur before the BCP operation is terminated. Each failed insert counts as one error. Default value is 10 (optional). If a value larger than 65,535 is specified, this field is set to 65,535.

    I would suggest for safety though also do an /e and output errors to a file for easy reference.

    You may also need to break the batch down if you will have more than 65535 errors possible.

    "Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)

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

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