From 3f1ef1b8e29f79d080d2d433fed249777218e20d Mon Sep 17 00:00:00 2001 From: Michael Hoennig Date: Mon, 6 Jan 2025 12:25:19 +0100 Subject: [PATCH] use real table to join partner to partner rel --- .../hsadminng/hs/office/debitor/HsOfficeDebitorEntity.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/net/hostsharing/hsadminng/hs/office/debitor/HsOfficeDebitorEntity.java b/src/main/java/net/hostsharing/hsadminng/hs/office/debitor/HsOfficeDebitorEntity.java index 44a37754..6181c6f4 100644 --- a/src/main/java/net/hostsharing/hsadminng/hs/office/debitor/HsOfficeDebitorEntity.java +++ b/src/main/java/net/hostsharing/hsadminng/hs/office/debitor/HsOfficeDebitorEntity.java @@ -88,9 +88,9 @@ public class HsOfficeDebitorEntity implements BaseEntity, ( SELECT DISTINCT partner.uuid FROM hs_office.partner_rv partner - JOIN hs_office.relation_rv dRel + JOIN hs_office.relation dRel ON dRel.uuid = debitorreluuid AND dRel.type = 'DEBITOR' - JOIN hs_office.relation_rv pRel + JOIN hs_office.relation pRel ON pRel.uuid = partner.partnerRelUuid AND pRel.type = 'PARTNER' WHERE pRel.holderUuid = dRel.anchorUuid )