| 28 | | SELECT "content_content"."id", "content_content"."created", "content_content"."description", "content_content"."disabled", "content_content"."modified", "content_content"."objectives", "content_content"."published", "content_content"."title", "content_content"."course_id", "content_content"."version_id", "content_content"."exercise_weight", "content_content"."midterm_weight", "content_content"."final_weight", "content_content"."project_weight", "content_content"."forum_weight", "content_content"."welcome_video", "content_content"."navigate_video", "content_content"."forum_video", "content_content"."lambda_fct_id", "content_content"."dl_key_version", "content_content"."dl_key_token", "content_content"."exam_key_token", "content_content"."lectures_url", GREATEST(EXISTS(SELECT V0."id", V0."created", V0."disabled", V0."modified", V0."title", V0."content_id", V0."owner_id", V0."post_id", V0."tag", V0."start", V0."uid", V0."question", V0."important", V0."resolved", V0."authorized", V0."votes", V0."mptt_id", V0."linked_content_type_id", V0."linked_content_id" FROM "forum_thread" V0 WHERE (V0."content_id" = "content_content"."id" AND NOT (V0."id" IN (SELECT U1."thread_id" FROM "forum_threadentry" U1 WHERE (U1."user_id" = 59 AND U1."thread_id" IS NOT NULL))))), False) AS "unread" FROM "content_content" INNER JOIN "content_teacher" ON ("content_content"."id" = "content_teacher"."content_id") LEFT OUTER JOIN "content_course" ON ("content_content"."course_id" = "content_course"."id") LEFT OUTER JOIN "content_version" ON ("content_content"."version_id" = "content_version"."id") WHERE ("content_teacher"."user_id" = 59 AND NOT ("content_content"."id" = 58) AND GREATEST(EXISTS(SELECT V0."id", V0."created", V0."disabled", V0."modified", V0."title", V0."content_id", V0."owner_id", V0."post_id", V0."tag", V0."start", V0."uid", V0."question", V0."important", V0."resolved", V0."authorized", V0."votes", V0."mptt_id", V0."linked_content_type_id", V0."linked_content_id" FROM "forum_thread" V0 WHERE (V0."content_id" = "content_content"."id" AND NOT (V0."id" IN (SELECT U1."thread_id" FROM "forum_threadentry" U1 WHERE (U1."user_id" = 59 AND U1."thread_id" IS NOT NULL))))), False)) ORDER BY "content_course"."uid" ASC, "content_version"."start" DESC |
| | 28 | SELECT "content_content"."id", "content_content"."created", "content_content"."description", "content_content"."disabled", "content_content"."modified", "content_content"."objectives", "content_content"."published", "content_content"."title", "content_content"."course_id", "content_content"."version_id", "content_content"."exercise_weight", "content_content"."midterm_weight", "content_content"."final_weight", "content_content"."project_weight", "content_content"."forum_weight", "content_content"."welcome_video", "content_content"."navigate_video", "content_content"."forum_video", "content_content"."lambda_fct_id", "content_content"."dl_key_version", "content_content"."dl_key_token", "content_content"."exam_key_token", "content_content"."lectures_url", |
| | 29 | EXISTS( |
| | 30 | SELECT V0."id", V0."created", V0."disabled", V0."modified", V0."title", V0."content_id", V0."owner_id", V0."post_id", V0."tag", V0."start", V0."uid", V0."question", V0."important", V0."resolved", V0."authorized", V0."votes", V0."mptt_id", V0."linked_content_type_id", V0."linked_content_id" FROM "forum_thread" V0 WHERE ( |
| | 31 | V0."content_id" = "content_content"."id" AND NOT ( |
| | 32 | V0."id" IN ( |
| | 33 | SELECT U1."thread_id" FROM "forum_threadentry" U1 WHERE ( |
| | 34 | U1."user_id" = 59 AND U1."thread_id" IS NOT NULL |
| | 35 | ) |
| | 36 | ) |
| | 37 | ) |
| | 38 | ) |
| | 39 | ) AS "unread" FROM "content_content" LEFT OUTER JOIN "content_course" ON ( |
| | 40 | "content_content"."course_id" = "content_course"."id" |
| | 41 | ) LEFT OUTER JOIN "content_version" ON ( |
| | 42 | "content_content"."version_id" = "content_version"."id" |
| | 43 | ) WHERE EXISTS( |
| | 44 | SELECT V0."id", V0."created", V0."disabled", V0."modified", V0."title", V0."content_id", V0."owner_id", V0."post_id", V0."tag", V0."start", V0."uid", V0."question", V0."important", V0."resolved", V0."authorized", V0."votes", V0."mptt_id", V0."linked_content_type_id", V0."linked_content_id" FROM "forum_thread" V0 WHERE ( |
| | 45 | V0."content_id" = "content_content"."id" AND NOT ( |
| | 46 | V0."id" IN ( |
| | 47 | SELECT U1."thread_id" FROM "forum_threadentry" U1 WHERE ( |
| | 48 | U1."user_id" = 59 AND U1."thread_id" IS NOT NULL |
| | 49 | ) |
| | 50 | ) |
| | 51 | ) |
| | 52 | ) |
| | 53 | ) ORDER BY "content_course"."uid" ASC, "content_version"."start" DESC |
| 34 | | SELECT "content_content"."id", "content_content"."created", "content_content"."description", "content_content"."disabled", "content_content"."modified", "content_content"."objectives", "content_content"."published", "content_content"."title", "content_content"."course_id", "content_content"."version_id", "content_content"."exercise_weight", "content_content"."midterm_weight", "content_content"."final_weight", "content_content"."project_weight", "content_content"."forum_weight", "content_content"."welcome_video", "content_content"."navigate_video", "content_content"."forum_video", "content_content"."lambda_fct_id", "content_content"."dl_key_version", "content_content"."dl_key_token", "content_content"."exam_key_token", "content_content"."lectures_url", GREATEST(EXISTS(SELECT (1) AS "a" FROM "forum_thread" V0 WHERE (V0."content_id" = "content_content"."id" AND NOT (EXISTS(SELECT (1) AS "a" FROM "forum_threadentry" U1 WHERE (U1."user_id" = 59 AND U1."thread_id" = V0."id") LIMIT 1))) LIMIT 1), False) AS "unread" FROM "content_content" INNER JOIN "content_teacher" ON ("content_content"."id" = "content_teacher"."content_id") LEFT OUTER JOIN "content_course" ON ("content_content"."course_id" = "content_course"."id") LEFT OUTER JOIN "content_version" ON ("content_content"."version_id" = "content_version"."id") WHERE ("content_teacher"."user_id" = 59 AND NOT ("content_content"."id" = 58) AND GREATEST(EXISTS(SELECT (1) AS "a" FROM "forum_thread" V0 WHERE (V0."content_id" = "content_content"."id" AND NOT (EXISTS(SELECT (1) AS "a" FROM "forum_threadentry" U1 WHERE (U1."user_id" = 59 AND U1."thread_id" = V0."id") LIMIT 1))) LIMIT 1), False)) ORDER BY "content_course"."uid" ASC, "content_version"."start" DESC |
| 35 | | }}} |
| | 59 | SELECT "content_content"."id", "content_content"."created", "content_content"."description", "content_content"."disabled", "content_content"."modified", "content_content"."objectives", "content_content"."published", "content_content"."title", "content_content"."course_id", "content_content"."version_id", "content_content"."exercise_weight", "content_content"."midterm_weight", "content_content"."final_weight", "content_content"."project_weight", "content_content"."forum_weight", "content_content"."welcome_video", "content_content"."navigate_video", "content_content"."forum_video", "content_content"."lambda_fct_id", "content_content"."dl_key_version", "content_content"."dl_key_token", "content_content"."exam_key_token", "content_content"."lectures_url", |
| | 60 | EXISTS( |
| | 61 | SELECT (1) AS "a" FROM "forum_thread" V0 WHERE ( |
| | 62 | V0."content_id" = "content_content"."id" AND NOT ( |
| | 63 | EXISTS( |
| | 64 | SELECT (1) AS "a" FROM "forum_threadentry" U1 WHERE ( |
| | 65 | U1."user_id" = 59 AND U1."thread_id" = V0."id" |
| | 66 | ) LIMIT 1 |
| | 67 | ) |
| | 68 | ) |
| | 69 | ) LIMIT 1 |
| | 70 | ) AS "unread" FROM "content_content" LEFT OUTER JOIN "content_course" ON ( |
| | 71 | "content_content"."course_id" = "content_course"."id" |
| | 72 | ) LEFT OUTER JOIN "content_version" ON ( |
| | 73 | "content_content"."version_id" = "content_version"."id" |
| | 74 | ) WHERE EXISTS( |
| | 75 | SELECT (1) AS "a" FROM "forum_thread" V0 WHERE ( |
| | 76 | V0."content_id" = "content_content"."id" AND NOT ( |
| | 77 | EXISTS( |
| | 78 | SELECT (1) AS "a" FROM "forum_threadentry" U1 WHERE ( |
| | 79 | U1."user_id" = 59 AND U1."thread_id" = V0."id" |
| | 80 | ) LIMIT 1 |
| | 81 | ) |
| | 82 | ) |
| | 83 | ) LIMIT 1 |
| | 84 | ) ORDER BY "content_course"."uid" ASC, "content_version"."start" DESC}}} |