1
0
Fork 0
mirror of https://github.com/immich-app/immich.git synced 2025-04-14 20:16:24 +02:00
immich/server/src/queries/map.repository.sql

22 lines
558 B
SQL

-- NOTE: This file is auto generated by ./sql-generator
-- MapRepository.getMapMarkers
select
"id",
"exif"."latitude" as "lat",
"exif"."longitude" as "lon",
"exif"."city",
"exif"."state",
"exif"."country"
from
"assets"
inner join "exif" on "assets"."id" = "exif"."assetId"
and "exif"."latitude" is not null
and "exif"."longitude" is not null
left join "albums_assets_assets" on "assets"."id" = "albums_assets_assets"."assetsId"
where
"isVisible" = $1
and "deletedAt" is null
and "ownerId" in ($2)
order by
"fileCreatedAt" desc