+ Reply to Thread
Results 1 to 5 of 5

Sort and compare multiple database outputs identifying variances.

  1. #1
    Registered User
    Join Date
    01-27-2013
    Location
    toronto,canada
    MS-Off Ver
    2007
    Posts
    2

    Sort and compare multiple database outputs identifying variances.

    Need help sorting and comparing output from 2 databases to identify inconsistencies. If an account and product is missing from one database a blank row should be inserted if variances are identified in quantities and value they should be highlighted .
    If a missing .

    The database currently has approx 800 accounts and growing .

    Output sample attached
    Attached Files Attached Files

  2. #2
    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: Sort and compare multiple database outputs identifying variances.

    Perhaps this macro solution will work for you?

    Run macro “Compare” to test.

    When using this macro layout must be same as in your uploaded file. When doing value comparison I found out that in Database 1 you had 7 decimals (formatting only shows 2) but in Database 2 you only have 2 decimals.

    The fix for that was to use the ROUND function setting decimals to 2 on both databases. This will not change your original values it just trims them when doing the comparing.

    Alf
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    01-27-2013
    Location
    toronto,canada
    MS-Off Ver
    2007
    Posts
    2

    Re: Sort and compare multiple database outputs identifying variances.

    Hi Alf thanks your macro worked great ... when running the macro against the entire database I've identified accounts that exist in Database # 2 ... is it possible to adjust the macro to enter a blank row in database # 1 as it does in Database #2

  4. #4
    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: Sort and compare multiple database outputs identifying variances.

    is it possible to adjust the macro to enter a blank row in database # 1 as it does in Database #2
    Sorry not possible. That will require a different approach. There is something funny about your data my guess is you copied tables as there seems to be limitations on what I can do with it. Have not managed to break this "conditional" setting yet.

    But as this has solved your original question I suggest you mark this thread "Solved" and post a new thread your added request.

    Alf

    Ps Tanks for comments and rep. Will look at possible solutions to your added request but in the meantime you will be better off by posting a new thread and get help from other forum members. When posting the new thread PM the link to me.
    Last edited by Alf; 01-31-2013 at 03:36 AM.

  5. #5
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Sort and compare multiple database outputs identifying variances.

    Can't you do this in the database they came from? This is trivial in SQL

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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