Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> comp.databases.theory -> Re: efficient compare
Christopher Browne wrote:
> In the last exciting episode, Bob Badour <bbadour_at_pei.sympatico.ca> wrote:
>
>>Andersen wrote: >> >> >>>Bob Badour wrote: >>> >>> >>>>I don't see how you are going to get log(N). >>> >>>log(N) message exchanges! Not bit complexity (i.e. size of the >>>messages). >> >>You are not going to get log(N) in messages either. >> >> >> >>>>Consider A & B are equal each with 65535 tuples. Insert a tuple >>>>into A at the beginning of the sort order. Insert a tuple into B at >>>>the end of the sort order. >>>> >>>>None of your subdivided sets are going to give matching checksums >>>>except in error until you get down to individual tuples. >>> >>>Here is a different solution to that problem. Keep N bins, where N >>>is some very large constant. Hash every tuple to an integer between >>>1-N and put it in the corresponding bin. Now run the divide and >>>conquer on this. >>>I.e, first send checksum of the value of all bins >> >>But you said N is a large number which means you have to send a large >>number of checksums.
But if you consider the example I gave previously that involved a single insert into each table, swapping logs would be trivial.
Likewise, by comparing the size of the log to the size of the relation variable, one could choose to send the relvar instead of the logs. However, one would then have trouble reconciling multiple changes to similar tuples. Received on Sun Apr 23 2006 - 08:17:15 CDT