Table Retail_Audit_All_Markets has PK on columns MC_Market_Code, Account, Product, Audit_Date, Activity. This is joined wiht table PODRIA_Reprocess that has PK on MC_Market_COde, Account, Product, min_Audit_Date. Tables are joined. As expected merge join operation is used, but it is followed by sort that sort on MC_Market_Code, Account, Product, Audit_Date, Activity. So same order as PK for table Retail_Audit_All_Markets and first part of PK PODRIA_Reprocess. So why is sort happening and what needs to be sorted?
By Wilfried 1 asked Oct 20, 2017 at 11:07 PM