This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Non-recursive, depth-limited (3 hops) descendant TXM count by direction. | |
// Bind params IN THIS ORDER: [direction, masterId, masterId, masterId] | |
export const SQL_COUNT_DESC_TXM = ` | |
SELECT COUNT(*) AS CNT | |
FROM ( | |
SELECT t.OBJ_ID | |
FROM FTM.TRANSMISSION_BASE t | |
JOIN FTM.CHANNEL c ON c.ID = t.CHANNEL_ID | |
WHERE c.INBOUND = ? | |
AND t.OBJ_ID IN ( |