remove old table
This commit is contained in:
parent
d96c8b2abb
commit
1f9df9ea5c
1 changed files with 2 additions and 8 deletions
|
|
@ -35,7 +35,6 @@ select
|
|||
p.amount as amount_in_txn_currency,
|
||||
p.currency,
|
||||
(p.amount * r.rate) as amount_in_gbp,
|
||||
(p.amount * nr.rate) as new_amount_in_gbp,
|
||||
ps.payment_status,
|
||||
p.notes
|
||||
from stg_core__verification_to_payment vtp
|
||||
|
|
@ -46,12 +45,7 @@ left join
|
|||
on vtp.id_verification_payment_type = vpt.id_verification_payment_type
|
||||
left join stg_core__payment_status ps on p.id_payment_status = ps.id_payment_status
|
||||
left join
|
||||
int_hardcoded_historical_currency_rates r
|
||||
on vtp.payment_due_date_utc = r.rate_date
|
||||
int_simple_exchange_rates r
|
||||
on vtp.payment_due_date_utc = r.rate_date_utc
|
||||
and p.currency = r.from_currency
|
||||
and r.to_currency = 'GBP'
|
||||
left join
|
||||
int_simple_exchange_rates nr
|
||||
on vtp.payment_due_date_utc = nr.rate_date_utc
|
||||
and p.currency = nr.from_currency
|
||||
and nr.to_currency = 'GBP'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue