KCL Software Solutions

Find Multiple Non-Target (Not Y) Terms in Taxonomy Link

The following Search SQL identifies instances of Linked Taxonomy Terms with more than one non-Y Term in the link:

EXISTS(SELECT * FROM CIC_BT_TAX tl WHERE tl.NUM=bt.NUM AND (SELECT COUNT(*) FROM CIC_BT_TAX_TM tlt WHERE tlt.BT_TAX_ID=tl.BT_TAX_ID AND tlt.Code NOT LIKE 'Y%') > 1)

Did you find this article helpful?