Hi,
you can use the
UNION
to get your desired result.
you can write the query following way.
SELECT Last_Date,
CASE WHEN ParameterId = 3 THEN Result END AS BPLaw,
'' AS BPHigh
FROM patient_progress_tracking_details
WHERE Patient_Id = 132
AND Tenant_Id = 1
AND Branch_Id = 1
AND Last_Date BETWEEN '2012-11-01' AND '2013-11-31'
group by Last_Date ;
UNION
SELECT Last_Date,
'' AS BPLaw,
CASE WHEN ParameterId = 4 THEN Result END AS BPHigh
FROM patient_progress_tracking_details
WHERE Patient_Id = 132
AND Tenant_Id = 1
AND Branch_Id = 1
AND Last_Date BETWEEN '2012-11-01' AND '2013-11-31'
group by Last_Date ;
I hope it will be help you.