I am currently working on a database project that involves creating an excel by extracting certain fields from a table in Access by using DAO.recordset. After doing the process of extracting information and assigning the correct names to some of the records in those fields I have duplicates that will need an sequence number that will identify them depending on some of the criteria from other columns. If I could get some guidance on how to accomplish this. right now, this process produces a CSV file, then it imports this CSV in the database, and then exports the file as XLS. I am hoping that this sequence can be done when the csv is imported into the database and assign the sequence numbers on the names that need it, and then continue to export the xls. If it's vba I am ok with it and is probably better for me if it's done with vba.