Linking datasets
In IQL, the LINK WITH clause enables you to use ‘glue’ datasets to link keys across datasets.
Rather than matching on a single ID, identifiers are probabilistically matched during each query using the information available.
In the example below, the offline and website datasets do not share the same identifiers for John Smith. But the Mobile dataset holds keys which can 'glue' the offline and website datasets together, so during a query the customer records can be matched.
To specify the linking dataset, simply write:
LINK WITH mydataset
You can include any number of datasets here. For example, write something like the following:
LINK WITH F, G
To bring it all together:
SELECT COUNT()
FROM
(A Union B) Exclude C
WHERE
Income >= 20000 AND
Age < 30
LINK WITH F, G