Reverse Intersect

stephen barncard stephenREVOLUTION2 at barncard.com
Tue May 25 18:08:33 EDT 2010


if you want to remove duplicate keys - put the imported data immediately
into an array. Duplicates are automatically eliminated.

On 25 May 2010 14:45, Bob Sneidar <bobs at twft.com> wrote:

> Hi all.
>
> I know the Intersect command removes keys in array-1  that don't exist in
> array-2. What I need however is a command that removes keys in array-1 that
> DO exist in array-2, so that array-1 contains all the keys I need to add.
> Why you ask? Why not just use the Union command? Because I need to find all
> the records in table-a that need to be added to table b. And since I am
> paging through table a a limited number of records at a time, (to prevent
> Rev memory overflow for large tables) I cannot simply use an SQL query join,
> and as I said in a prior post the tables are in disconnected databases.
>
> So what I am doing is getting 100 records from table-a as a string,
> massaging it a bit to form a comma delimited list, then using the SQL IN
> operator to get what records there are in table-b that are already in
> table-a. At that point I need to eliminate the table-b keys from the table-a
> keys, and what I will have left are the keys that need to be inserted into
> table-b. Simple. See? ;-)
>
> So is there any way to do this without a repeat loop? I can always do a
> repeat loop, but they weary me. <sigh> ;-)
>
> Bob
>
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
>



-- 
-------------------------
Stephen Barncard
San Francisco



More information about the use-livecode mailing list