62 | | SELECT "testquery_parentlink"."id", "testquery_parentlink"."enabled" FROM "testquery_parentlink" LEFT OUTER JOIN "testquery_childlink" ON ("testquery_parentlink"."id" = "testquery_childlink"."parent_link_id") WHERE ((NOT (EXISTS(SELECT 1 AS "a" FROM "testquery_childlink" U1 WHERE (U1."origin_child_id" = 1 AND U1."parent_link_id" = ("testquery_parentlink"."id")) LIMIT 1)) OR (NOT "testquery_childlink"."enabled" AND "testquery_childlink"."origin_child_id" = 1)) AND "testquery_parentlink"."enabled") |
| 62 | SELECT "testquery_parentlink"."id", |
| 63 | "testquery_parentlink"."enabled" |
| 64 | FROM "testquery_parentlink" |
| 65 | LEFT OUTER JOIN "testquery_childlink" ON ("testquery_parentlink"."id" = "testquery_childlink"."parent_link_id") |
| 66 | WHERE ((NOT (exists |
| 67 | (SELECT 1 AS "a" |
| 68 | FROM "testquery_childlink" u1 |
| 69 | WHERE (u1."origin_child_id" = 1 |
| 70 | AND u1."parent_link_id" = ("testquery_parentlink"."id")) |
| 71 | LIMIT 1)) |
| 72 | OR (NOT "testquery_childlink"."enabled" |
| 73 | AND "testquery_childlink"."origin_child_id" = 1)) |
| 74 | AND "testquery_parentlink"."enabled") |
81 | | SELECT "testquery_parentlink"."id", "testquery_parentlink"."enabled" FROM "testquery_parentlink" LEFT OUTER JOIN "testquery_childlink" ON ("testquery_parentlink"."id" = "testquery_childlink"."parent_link_id") WHERE (((NOT "testquery_childlink"."enabled" AND "testquery_childlink"."origin_child_id" = 1) OR NOT (EXISTS(SELECT 1 AS "a" FROM "testquery_childlink" U1 WHERE (U1."origin_child_id" = 1 AND U1."id" = ("testquery_childlink"."id") AND "testquery_childlink"."parent_link_id" = ("testquery_parentlink"."id")) LIMIT 1))) AND "testquery_parentlink"."enabled") |
| 93 | SELECT "testquery_parentlink"."id", |
| 94 | "testquery_parentlink"."enabled" |
| 95 | FROM "testquery_parentlink" |
| 96 | LEFT OUTER JOIN "testquery_childlink" ON ("testquery_parentlink"."id" = "testquery_childlink"."parent_link_id") |
| 97 | WHERE (((NOT "testquery_childlink"."enabled" |
| 98 | AND "testquery_childlink"."origin_child_id" = 1) |
| 99 | OR NOT (exists |
| 100 | (SELECT 1 AS "a" |
| 101 | FROM "testquery_childlink" u1 |
| 102 | WHERE (u1."origin_child_id" = 1 |
| 103 | AND u1."id" = ("testquery_childlink"."id") |
| 104 | AND "testquery_childlink"."parent_link_id" = ("testquery_parentlink"."id")) |
| 105 | LIMIT 1))) |
| 106 | AND "testquery_parentlink"."enabled") |