chore: no sql generation for queries with side effects (#18301)

no sql generation for queries with side effects
This commit is contained in:
Mert
2025-05-14 23:34:22 -04:00
committed by GitHub
parent 6a4d21205f
commit 709a7b70aa
20 changed files with 48 additions and 167 deletions

View File

@@ -100,50 +100,6 @@ where
"sharedWithId" = $1
and "sharedById" = $2
-- PartnerRepository.create
insert into
"partners" ("sharedWithId", "sharedById")
values
($1, $2)
returning
*,
(
select
to_json(obj)
from
(
select
"id",
"name",
"email",
"avatarColor",
"profileImagePath",
"profileChangedAt"
from
"users" as "sharedBy"
where
"sharedBy"."id" = "partners"."sharedById"
) as obj
) as "sharedBy",
(
select
to_json(obj)
from
(
select
"id",
"name",
"email",
"avatarColor",
"profileImagePath",
"profileChangedAt"
from
"users" as "sharedWith"
where
"sharedWith"."id" = "partners"."sharedWithId"
) as obj
) as "sharedWith"
-- PartnerRepository.update
update "partners"
set