September 24, 2007 at 4:24 am
Hi,
Can I have a script to compare the two tables. Such that I can identify the missing rows of Table A in Table B, in the absece of any know key.
September 24, 2007 at 4:40 am
To compare without knowing what you are comparing doesn't make sense. You could try to look whether two tables are identical, but if the column names are different, then you need to provide some comparing pattern - which column in table A will be compared with which in table B.
September 24, 2007 at 5:29 am
Vladan's right, you MUST be able to identify what makes a row "unique"; it may be a combination of 5 fields, or it may be every field. that is the "key" you must identify before you can compare table to table to look for missing items.
give us the table structure, and what you've identified that makes the row in the table as unique, and we can offer some good examples.
Lowell
September 24, 2007 at 5:36 am
September 25, 2007 at 12:43 am
Yes Adrian,
You may count it as a cross post, but I put it under a different subject to know if there is any generic sql script that can compare two tables and find the unmatched rows without asking for a key or set of keys.
Regards
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply