In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Beau E. Cox) writes: >Hi - > >Wait! If you are going to load the data into a database anyway, >why not use the existing database (or the one being created) to >remove duplicates. You don't even have to have an index on the >column you are making unique (but it would be _much_ faster). >Just select on you key, and, if found, reject the datum as >a duplicate. You really shouldn't have to go to any draconian >measures to find duplicates!
No need even to do that. Just set a primary key constraint on the database table (like all good tables should have anyway) and you're done. (Or if the "duplicate" criterion involves some other column, put a UNIQUE constraint on it.) Then all inserts of duplicate records will fail automatically. Just make sure that RaiseError is set to false in the DBI connect. -- Peter Scott http://www.perldebugged.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]