{"id":640,"date":"2014-06-25T19:31:54","date_gmt":"2014-06-26T02:31:54","guid":{"rendered":"https:\/\/blogs.plm.automation.siemens.com\/t5\/Polarion-Blog\/Tech-Tips-amp-Tricks-Test-Run-to-Test-Case-Coverage\/ba-p\/380865"},"modified":"2026-03-26T05:29:28","modified_gmt":"2026-03-26T09:29:28","slug":"tech-tips-tricks-test-run-to-test-case-coverage","status":"publish","type":"post","link":"https:\/\/blogs.sw.siemens.com\/polarion\/tech-tips-tricks-test-run-to-test-case-coverage\/","title":{"rendered":"Tech Tips &#038; Tricks: Test Run-to-Test Case Coverage"},"content":{"rendered":"<p>Welcome to another installment in our series of tips and tricks from the Polarion Software Technical Support team, in which we share solutions we provided to customers for real-world use cases that. The same tips might help you too, or others on your team. Today&#8217;s post is a quickie: easy reporting on Test Run &#8211; Test Case&nbsp;coverage using SQL.<!--more--><br \/>\n<H2>Use Case<\/H2><br \/>\nYou want to trace Test Cases to Test Runs. Specifically, you need to identify Test Cases that are not included in Test Runs at any given time.<br \/>\n<H2>Solution<\/H2><br \/>\nAs with the last several posts, we find that Lucene, while fine for many querying needs, doesn&#8217;t deliver information like this&#8230; at least not in a way the doesn&#8217;t tax the system too much. Here&#8217;s some Wiki page mark-up you can use to find your Test Cases that are not part of any Test Run.<br \/>\n<PRE style=\"line-height: normal; border: 1px dashed #999; background-color: #f8f8f8; padding: 10px;\">1 Test Cases Not Included in Test Runs<\/p>\n<p>1 Query<br \/>\n#set($myQuery = &#8220;SELECT test.C_PK FROM WORKITEM test, PROJECT proj WHERE =&gt;<br \/>\ntest.FK_URI_PROJECT = proj.C_URI AND proj.C_ID = &#8216;${page.getProject()}&#8217; AND =&gt;<br \/>\ntest.C_TYPE = &#8216;testcase&#8217; AND NOT EXISTS (SELECT record.* FROM =&gt;<br \/>\nSTRUCT_TESTRUN_RECORDS record WHERE record.FK_URI_TESTCASE = test.C_URI)&#8221;)<br \/>\n* $myQuery<\/p>\n<p>1.1 TestCases<br \/>\n{workitems:sqlQuery=$myQuery}<br \/>\n<\/PRE><br \/>\n<P style=\"font-size: smaller; text-align: right;\">=&gt; indicates continuation on the same line.<\/P><\/p>\n<p><HR \/><\/p>\n<p><EM>Jiri Jandl is a Senior Support Engineer with Polarion Software&#8217;s European tech support team. He is based in Prague, Czech Republic.<\/EM><\/p>\n<p><HR \/><br \/>\n<P style=\"text-align: center;\"><A href=\"http:\/\/www.polarion.com\/techsupport\/index.php#support-level\" rel=\"nofollow noopener noreferrer\"><IMG class=\"alignnone size-full wp-image-5839\" src=\"http:\/\/community.plm.automation.siemens.com\/legacyfs\/online\/siemensplm_blogs\/2014\/06\/polarion-silver-gold-support.jpg\" alt=\"Banner: It's all about solutions - Polarion Silver and Gold Support\" width=\"700\" height=\"150\" \/><\/A><\/P><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Welcome to another installment in our series of tips and tricks from the Polarion Software Technical Support team, in which we share solutions we provided to customers for real-world use cases that. &#8230;<\/p>\n","protected":false},"author":54129,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"spanish_translation":"","french_translation":"","german_translation":"","italian_translation":"","polish_translation":"","japanese_translation":"","chinese_translation":"","footnotes":""},"categories":[1],"tags":[],"industry":[],"product":[],"coauthors":[],"class_list":["post-640","post","type-post","status-publish","format-standard","hentry","category-news"],"_links":{"self":[{"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/posts\/640","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/users\/54129"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/comments?post=640"}],"version-history":[{"count":1,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/posts\/640\/revisions"}],"predecessor-version":[{"id":641,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/posts\/640\/revisions\/641"}],"wp:attachment":[{"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/media?parent=640"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/categories?post=640"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/tags?post=640"},{"taxonomy":"industry","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/industry?post=640"},{"taxonomy":"product","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/product?post=640"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/polarion\/wp-json\/wp\/v2\/coauthors?post=640"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}