+ Reply to Thread
Results 1 to 3 of 3

VBA Excel - macros for sorting, filtering and removing duplicated records from DB

  1. #1
    Registered User
    Join Date
    02-09-2016
    Location
    Bucharest
    MS-Off Ver
    2013
    Posts
    53

    Thumbs up VBA Excel - macros for sorting, filtering and removing duplicated records from DB

    Hello friends,

    I'm dealing with very big files, hundred of thousands of lines Excel files, almost on a daily basis.
    Now i need to perform some reports, with data from these files.

    Since i'm doing this like a robot, in order to reduce time, i need some help to do a macro to automate this process.
    The output of this macro should do some sorting, filtering, counting the total number of records and displaying the most 3 active values, then to reduce these by discarding duplacted values of column A+B:


    1. Sort by column A and then by column D (2 criterias)
    2. Convert feedback number (Column C) into feedback word
    3. Select only records from February 2017
    4. Convert date from previous format in Custom format (mmmm dd, yyyy hh:mm:ss AM/PM)
    5. Extract Top 3 most active tourists on February 2017 (based on number of total records)
    6. Extract Top 3 most visited cities on February 2017 (based on total number of records)
    7. Extract Top 3 most visited continents on February 2017 (based on total number of records)
    8. Remove all the duplicated records from Columns A & B (E.g.: Alpha - Berlin, to keep only one record)
    9. From the newly reduced list, to keep only the records based on selection list from Sheet 2, Column C, discarding all other records that are not on the list (only specific cities).


    Thank you in advance
    Attached Files Attached Files

  2. #2
    Registered User
    Join Date
    02-09-2016
    Location
    Bucharest
    MS-Off Ver
    2013
    Posts
    53

    Re: VBA Excel - macros for sorting, filtering and removing duplicated records from DB

    I modified a little the table makeing it more simple. So, the cities are grouped unde separate columns, each of them has a column header, the Continent.

    Is there any way to create a new excel file, blank one like a template, that contains these macros and when the macro is running, to import the data from the DB excel, so the output to be with reduced number of records?

    Any ideas?

    Thank you
    Attached Files Attached Files
    Last edited by tuspilica; 05-07-2017 at 05:25 AM.

  3. #3
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: VBA Excel - macros for sorting, filtering and removing duplicated records from DB

    macro is running, to import the data from the DB excel, so the output to be with reduced number of records?
    I would probably have a master file with all the macros and running the macro and importing the data I would then save my modified master file as an xlsx file (file saved with all data but without macros) with i new name and then close it.

    In this way you keep your original master file intact and you can use it again and again.

    The rest of your request I find rather extensive so perhaps you take a look at the forums "Commercial Services" where you can get your problem solved for a fee by the forums best brains.

    Alf

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Help filtering/removing/or sorting French and English
    By Yhaw in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-17-2015, 02:33 PM
  2. Excel 2010: Removing Duplicated Run On Text from a Column
    By MistaMaDD in forum Excel General
    Replies: 2
    Last Post: 05-11-2011, 04:15 PM
  3. Sorting duplicated data with excel
    By Swwils in forum Excel General
    Replies: 3
    Last Post: 02-04-2011, 07:47 AM
  4. sorting and filtering and removing hidden records
    By johnmerlino in forum Access Tables & Databases
    Replies: 3
    Last Post: 10-05-2010, 04:35 PM
  5. Sorting and Filtering the records to new worksheet
    By saikumar in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 01-20-2009, 02:24 AM
  6. viewing duplicated records
    By brain_chilled in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-30-2008, 04:53 PM
  7. [SOLVED] How do you use filter to view duplicated records in Excel?
    By Sharon in forum Excel General
    Replies: 2
    Last Post: 01-09-2006, 09:30 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1