Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Looking for differences...
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00445792
Message ID:
00446006
Views:
18
>Scan the first, seek the matching record in the second, then scatter both records to objects (Scatter name MyObjName). Then use CompObj to compare the two objects. If one field is different you'll get a FALSE return.
>
>You'll also have to determine if there are records in the second table that are not in the first, but you can use SQL-Select for that
>
>SELECT MyIDField from Table2 where MyIDField not in (Select MyIDField from Table1) into cursor curNotInTable1
>
>HTH
>Barbara
>

Hi Barbara,

This method tells you, if there is a difference, but how would you obtain the fields name, which are different and the values? You still have to iterate through afields() then.

>>I have two tables with identical structures and record counts. I need a quick way to extract the different rows from either table into a cursor or table. The differences might be a single field or more. Both tables have an integer PK and are in sync. Any thoughts? TIA
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform