Making a duplicate table 
Author Message
 Making a duplicate table

Hi,
    i need to create a copy of certain records from my recordset which i
believe to be duplicate records.  This is so i can allow the user to
highlight the records he agreesa are duplicates and then i can delete them
from the main table.  How can i create a temporary table based on the
structure of the main table.

By the way iam using access2k and vb6 and ado2.1

Thanks in advance

Tim



Mon, 29 Jul 2002 03:00:00 GMT  
 Making a duplicate table
If the temp table doesn't exist you can use:

    SELECT * FROM Table1 INTO TempTable WHERE <criteria to identify dups in
Table1>;

If you need to append data to the temporary table you can use:

    INSERT INTO TempTable SELECT * FROM Table1 WHERE <criteria to identify
dups in Table1>;

These SQL statements could just be passed as strings to the Execute method
of ADO's Connection object.

-Paul

--------------------------------------------------------
Paul Little, Senior Programmer/Analyst
SVi Retail Systems
San Diego, CA


Quote:
> Hi,
>     i need to create a copy of certain records from my recordset which i
> believe to be duplicate records.  This is so i can allow the user to
> highlight the records he agreesa are duplicates and then i can delete them
> from the main table.  How can i create a temporary table based on the
> structure of the main table.

> By the way iam using access2k and vb6 and ado2.1

> Thanks in advance

> Tim



Mon, 29 Jul 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Update a Table from another Table without duplicates

2. making a duplicate of an ado recordset?

3. Finding Duplicate and append unique/ joining 2 tables in Access97

4. moving almost duplicate records to a different table

5. Checking if a record is duplicated before adding or during adding it to a table

6. Duplicate records to new Table

7. Deleting Duplicate Records in a Table?

8. Err No rows at, duplicate table and row names

9. How to duplicate a table in VB6?

10. Q: Duplicating Data vs Linking Tables

11. How do you delete duplicate records from Access table

12. How to Delete Duplicate records in Access Table ??

 

 
Powered by phpBB® Forum Software