|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
**Really stuck on this** please help - Duplicate data
<i><b>Originally posted by : GMan (gvyas2000@hotmail.com)</b></i><br />I receive the data into one of my tables on MS SQL Server from a text file which has some duplicate records. How do I delete them? For example, here is what my SQL table is with two fields and three records:<br />Field1; Field2<br />AB; DE<br />AB; DE<br />AB; 12<br /><br />So here 1 and 2 are duplicates but 3 is not since the Field2 is not the same. So basically all the fields value has to be same, not just one field. <br />I was thinking of writing some kind of SP to search those duplicates or a trigger, how to do that? <br /><br /><br /><br />
|
|
#2
|
|||
|
|||
|
<i><b>Originally posted by : Dave B (david_baylor@yahoo.com)</b></i><br /><br />Just create an index on that table that includes all the fields and set it to "no dups"<br /><br />------------<br />GMan at 3/29/2000 9:47:56 AM<br /><br />I receive the data into one of my tables on MS SQL Server from a text file which has some duplicate records. How do I delete them? For example, here is what my SQL table is with two fields and three records:<br />Field1; Field2<br />AB; DE<br />AB; DE<br />AB; 12<br /><br />So here 1 and 2 are duplicates but 3 is not since the Field2 is not the same. So basically all the fields value has to be same, not just one field. <br />I was thinking of writing some kind of SP to search those duplicates or a trigger, how to do that? <br /><br /><br /><br />
|
![]() |
| Viewing: ASP Free Forums > Programming > ASP Development > **Really stuck on this** please help - Duplicate data |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|