0 Replies Latest reply on Jan 17, 2014 7:26 AM by osman1156

    whd database table linkage


      We run a customized report out of the help desk database for out IT department ticket status.
      SELECT *
      FROM ("whd"."public"."job_ticket" "job_ticket" INNER JOIN "whd"."public"."status_type" "status_type"
      ON "job_ticket"."status_type_id"="status_type"."status_type_id") LEFT OUTER JOIN "whd"."public"."tech" "tech"
      ON "job_ticket"."assigned_tech_id"="tech"."client_id"
      WHERE ("status_type"."status_type_id"=1 OR "status_type"."status_type_id"=2 OR "status_type"."status_type_id"=5 OR "status_type"."status_type_id"=7 OR "status_type"."status_type_id"=8)
      AND "job_ticket"."deleted"=0
      AND ("job_ticket"."location_id"=2 OR "job_ticket"."location_id"=6 OR "job_ticket"."location_id"=8)
      AND "tech"."supervisor_id"=29
      ORDER BY "job_ticket"."status_type_id", "job_ticket"."assigned_tech_id"
      The issue is the "unassigned" tickets does not have information that I can link it up to the query since the supervisor id for those tickets are "null" at that point.

      I want to link my query to the "email_account" table and filter by specific email account or any other means.

      Please help?