Vote count:
0
I am using the below query to get the result we have been using but now we want to change the output format please see the required output. I have tried using Group by clause but that it did not change anything. Please help me with this.
SELECT
CF_ITEM_NAME as "Test lab Folder Name",
CYCLE.CY_CYCLE as "Test Set Name",
TEST.TS_NAME as "Test Case Name",
STEP.ST_STEP_NAME as "Step Name",
TEST.TS_EXEC_STATUS as "Plan: Test Exec Latest Status",
RUN.RN_STATUS as "Run Exec Status",
RUN.RN_TESTER_NAME as "Tester",
(SUBSTRING(CONVERT(VARCHAR, RUN.RN_EXECUTION_DATE, 25), 1, 11) + CONVERT(VARCHAR, RUN.RN_EXECUTION_TIME, 8)) as "Exec Date"
FROM TD.CYCL_FOLD
LEFT OUTER JOIN TD.CYCLE
ON CYCL_FOLD.CF_ITEM_ID = CYCLE.CY_FOLDER_ID
LEFT OUTER JOIN TD.TESTCYCL
ON TESTCYCL.TC_CYCLE_ID = CYCLE.CY_CYCLE_ID
LEFT OUTER JOIN TD.RUN /*Run*/
ON RN_TESTCYCL_ID = TC_TESTCYCL_ID AND RN_RUN_ID IN (SELECT MAX(RN_RUN_ID) FROM TD.RUN GROUP BY RN_TESTCYCL_ID)
LEFT OUTER JOIN TD.TEST /*Test*/
ON RUN.RN_TEST_ID = TEST.TS_TEST_ID
LEFT OUTER JOIN TD.STEP
ON STEP.ST_RUN_ID = RUN.RN_RUN_ID --ON STEP.ST_TEST_ID = TEST.TS_TEST_ID
LEFT OUTER JOIN TD.RELEASE_CYCLES
ON TESTCYCL.TC_ASSIGN_RCYC = RELEASE_CYCLES.RCYC_ID
WHERE CYCL_FOLD.CF_ITEM_PATH LIKE 'AAAAAAAAE%'
ORDER BY CYCLE.CY_CYCLE,TEST.TS_NAME
Result:
Test lab folder name testsetname testcasename stepname test cycle1 calico 2.2.1 confirm the value step1 test cycle1 calico 2.2.1 confirm the value step2 test cycle1 calico 2.2.1 verify the value new1 test cycle1 calico 2.2.1 verify the value new2
Output required:
Test lab folder name testsetname testcasename stepname test cycle1 calico 2.2.1 confirm the value step1 test cycle1 calico 2.2.1 step2 test cycle1 calico 2.2.1 verify the value new1 test cycle1 calico 2.2.1 new2
asked 1 min ago
Group data using the below query
Aucun commentaire:
Enregistrer un commentaire