Changes

SQL Saved search Task

648 bytes added, 09:49, 13 February 2014
no edit summary
hazard_localid
</pre>
'''Hazard included in more than one Task''' which could be OK depending on the business rules<pre>SELECThazard.hazard_localid,Count(task_has_objective.task_guid)FROMhazardInner Join task_has_objective ON hazard.hazard_guid = task_has_objective.hazard_guidGROUP BYhazard.hazard_localidHAVINGCount(task_has_objective.task_guid) > '1'ORDER BYhazard.hazard_localid ASC</pre>'''Tasks without Objectives''' which could be OK depending on the business rules<pre>SELECT task.localidFROM task_has_objective Right Join task ON task.guid = task_has_objective.task_guid where task_has_objective.task_guid IS NULLORDER BYtask.localid</pre>
[[Category:NoPublic]]
[[Category:SQL Queries]]
6,632
edits