Professional Web Applications Themes

Compare record in two tables, return fields that don't match... - MySQL

Does anyone know if there is an easy way to compare a row from table a, to a row in table b with the same structure/field names and return those fields which don't match? I have table_a storing the originally submitted applicant information, and table_b storing a version that can be changed. When a user makes a change I'd like to compare it to the original table to see what fields were changed, preferably without opening the row from both tables and going field by field in code to see if they match... Thank you for the help! Nick Smith ...

  1. #1

    Default Compare record in two tables, return fields that don't match...

    Does anyone know if there is an easy way to compare a row from table
    a, to a row in table b with the same structure/field names and return
    those fields which don't match?

    I have table_a storing the originally submitted applicant information,
    and table_b storing a version that can be changed. When a user makes a
    change I'd like to compare it to the original table to see what fields
    were changed, preferably without opening the row from both tables and
    going field by field in code to see if they match...

    Thank you for the help!

    Nick Smith
    Application Developer
    Influent Inc.

    NickSmith@influentinc.com Guest

  2. #2

    Default Re: Compare record in two tables, return fields that don't match...

    Nick,

    Do you have an option of using a third-party utility? If yes, try WinSQL
    (www.synametrics.com). It can find differences between data as well as
    schema.



    com wrote: 
    Azhar Guest

  3. #3

    Default Re: Compare record in two tables, return fields that don't match...

    On Jul 9, 9:56 am, com wrote: 

    Nick,

    check out xSQL Software's product (www.xsqlsoftware.com), xSQL SDK if
    you want to write a few lines of code yourself and manipulate the
    results any way you wish, or xSQL Data Compare if all you need is to
    see what has changed. Those products are free for smaller databases
    (based on number of objects in the database) and also free for SQL
    Server Express with no limitations. They support both SQL Server 2000
    and SQL Server 2005.

    Hope this helps.


    Thanks,
    JC
    xSQL Software
    http://www.xsqlsoftware.com

    xman Guest

Similar Threads

  1. Compare MS SQL Tables
    By DFR in forum Coldfusion Database Access
    Replies: 7
    Last Post: August 7th, 08:34 PM
  2. Compare 2 tables
    By cwmcguire in forum Coldfusion - Getting Started
    Replies: 4
    Last Post: February 9th, 01:26 PM
  3. How do I compare two tables?
    By Lord Merlin in forum ASP Database
    Replies: 3
    Last Post: July 20th, 11:50 AM
  4. compare two tables?
    By Lord Merlin in forum ASP Components
    Replies: 1
    Last Post: July 12th, 12:21 AM

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
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139