Du kan ge en fråga ett namn eller alias med CTE:s (Common Table Expressions) aka WITH-sats aka av Oracle som Subquery Factoring:
WITH abc as (select client_ref_id, request from some_table where message_type = 1)
select *
from abc
inner join
(select client_ref_id, response from some_table where message_type = 2) defg
on abc.client_ref_id = def.client_ref_id;