if exists (
select 1
from 'creditor'
join 'creditor-instrument data' on
'creditor'.'reporting agent identifier' = 'creditor-instrument data'.'reporting agent identifier' and
'creditor'.'counterparty identifier' = 'creditor-instrument data'.'counterparty identifier' and
'creditor'.'counterparty role' = 'creditor-instrument data'.'counterparty role' and
'creditor'.'reporting reference date' = 'creditor-instrument data'.'reporting reference date'
join 'instrument' on
'creditor-instrument data'.'reporting agent identifier' = 'instrument'.'reporting agent identifier' and
'creditor-instrument data'.'observed agent identifier' = 'instrument'.'observed agent identifier' and
'creditor-instrument data'.'contract identifier' = 'instrument'.'contract identifier' and
'creditor-instrument data'.'instrument identifier' = 'instrument'.'instrument identifier' and
'creditor-instrument data'.'reporting reference date' = 'instrument'.'reporting reference date'
join 'instrument-protection received data' on
'instrument'.'reporting agent identifier' = 'instrument-protection received data'.'reporting agent identifier' and
'instrument'.'observed agent identifier' = 'instrument-protection received data'.'observed agent identifier' and
'instrument'.'contract identifier' = 'instrument-protection received data'.'contract identifier' and
'instrument'.'instrument identifier' = 'instrument-protection received data'.'instrument identifier' and
'instrument'.'reporting reference date' = 'instrument-protection received data'.'reporting reference date'
join 'protection received' on
'instrument-protection received data'.'reporting agent identifier' = 'protection received'.'reporting agent identifier' and
'instrument-protection received data'.'protection identifier' = 'protection received'.'protection identifier' and
'instrument-protection received data'.'reporting reference date' = 'protection received'.'reporting reference date'
join 'protection provider-protection received' on
'protection received'.'reporting agent identifier' = 'protection provider-protection received'.'reporting agent identifier' and
'protection received'.'protection identifier' = 'protection provider-protection received'.'protection identifier' and
'protection received'.'reporting reference date' = 'protection provider-protection received'.'reporting reference date'
where 'protection provider-protection received'.'reporting agent identifier' = 'creditor'.'reporting agent identifier'
and 'protection provider-protection received'.'counterparty identifier' = 'creditor'.'counterparty identifier'
and 'protection provider-protection received'.'reporting reference date' = 'creditor'.'reporting reference date')
|