Hello guys,
I have to create a stored procedure that generates a recordset and fill a table with the data retrieved by the stored procedure.
The table has a key with 2 fields, employee number and a process date.
The Stored procedure must be executed every month and the table can store more than one record per employee, but I can't store duplicated data for the same employee. for example :

on May 2005, The stored procedure find something like this :

employee_num Process_Date Field1 Field2 Field3....
1 05/31/2005 A B C

On June 2005, The Stored Procedure don't find me, so no record for me in that month

On July 2005, The Stored Procedure find me again with this data :

employee_num Process_Date Field1 Field2 Field3....
1 07/31/2005 D E F

I should see this information in the table :

employee_num Process_Date Field1 Field2 Field3....
1 05/31/2005 A B C
1 07/31/2005 D E F

But it's not possible to have something like this :

employee_num Process_Date Field1 Field2 Field3....
1 05/31/2005 A B C
1 05/31/2005 A B C

The problem is that if the stored procedure finds a duplicate record i get the next error message :

Server: Msg 2627, Level 14, State 1, Line 1
Violation of PRIMARY KEY constraint 'PK_TABLE_NAME'. Cannot insert duplicate key in object 'TABLE_NAME'.
The statement has been terminated.

The SQL Statament I used to insert the records into the table is something like this :

INSERT INTO TABLE_NAME

SELECT

Employe_Num
Process_Date
Field1
Field2
Field3

FROM

.....


The problem is that it doesn't inserts the records that MUST be inserted into the table either because if the statement finds a duplicate key, it stops all the process.
I'be been thinking about creating a VBP and scroll all the recordset inserting into the table only the records I need, but I want to do it directly in SQL Server.
How can I solve this problem in Transact SQL ? (Stored Procedures, Triggers, etc)

Thank you all