Firepen
06-10-2020, 04:20 AM
Hi Guys, I'm having a little trouble with something.
I want to see if a combination of fields, say columns C+D, already exist as a combination in Columns A+B anywhere in the table (not just the same record.) If they do not, then I want to move the values from C&D over to A&B, if they do I would want to delete that record.
This is part of a data import and transformation module for tables that sit behind Cascade Combo Boxes, so currently the old data is in the A&B Columns and new data is in new records with data only in C&D (Data types do not yet match). I have pulled the unique combinations from the new data set out but some will match existing combinations.
Origianlly tried SQL EXISTS but this only checks the record, I suspect I need a Do Loop but not sure how to start with this query. Would appreciate any guidence.
Many Thanks,
I want to see if a combination of fields, say columns C+D, already exist as a combination in Columns A+B anywhere in the table (not just the same record.) If they do not, then I want to move the values from C&D over to A&B, if they do I would want to delete that record.
This is part of a data import and transformation module for tables that sit behind Cascade Combo Boxes, so currently the old data is in the A&B Columns and new data is in new records with data only in C&D (Data types do not yet match). I have pulled the unique combinations from the new data set out but some will match existing combinations.
Origianlly tried SQL EXISTS but this only checks the record, I suspect I need a Do Loop but not sure how to start with this query. Would appreciate any guidence.
Many Thanks,