We are attempting to combine two data sets from different sources that revolve around a common key. The first source has a map from Account ID (many) to Customer Code (one). The second source has a map from Location (many) to Customer Code (one). The result should be all permutations of Account ID to Location that we will insert new records from.
For example, one Customer Code has 3 accounts associated and is present in two locations. The result of this should be 6 documents. I've been trying to use cache lookups, but I can't seem to get the right combination of caches and indexes to make this scenario work.
Any help would be greatly appreciated!