You need case clause, which put value in right column.
SELECT
e.patientid,
e.indexpatient,
e.indexstudy,
e.studydatetime,
e.lastname,
e.firstname,
p.parameterID,
case
when p.parameterID = 'AVA (VTI)' then sum(p.resultvalue)
end as AVA,
case
when p.parameterID = '2D/Ao Root Diam' then sum(p.resultvalue)
end as 2D,
case
when p.parameterID = '2D/Ao Root Diam' then sum(p.resultvalue)
end as 3D
FROM dbcreators.gems_examview e,
dbcreators.parameter p
WHERE p.parameterID
in
('AVA (VTI)', '2D/Ao Root Diam', '2D/Ao asc Diam')
and
e.studydatetime<'2014-02-28' and e.studydatetime>'2009-04-12' and
p.indexpatient = e.indexpatient and p.indexstudy = e.indexstudy and
p.indexseries = e.indexseries and p.resultno = -1
group by e.patientid,
e.indexpatient,
e.indexstudy,
e.studydatetime,
e.lastname,
e.firstname,
p.parameterID
order by patientid desc