-
I have searched the existing issues, both open and closed, to make sure this is not a duplicate report.
The bugUnsure when it first occurred, but at least present in v1.129 and v1.130. All shared links fail to load. Running with the official docker image(s) in kubernetes (k3s) using the TrueCharts helm chart The OS that Immich Server is running onFedora 41 Version of Immich Serverv1.130 Version of Immich Mobile AppN/A Platform with the issue
Your docker-compose.yml contentN/A not using docker-composeYour .env contentN/A not using .env can provide any other setup details as neededReproduction steps
Relevant log outputQuery failed : {
durationMs: 1.1743639999767765,
error: PostgresError: column "albums.ownerId" must appear in the GROUP BY clause or be used in an aggregate function
at ErrorResponse (/usr/src/app/node_modules/postgres/cjs/src/connection.js:788:26) immich at handle (/usr/src/app/node_modules/postgres/cjs/src/connection.js:474:6)
at Socket.data (/usr/src/app/node_modules/postgres/cjs/src/connection.js:315:9)
at Socket.emit (node:events:518:28) immich at addChunk (node:internal/streams/readable:561:12)
at readableAddChunkPushByteMode (node:internal/streams/readable:512:3)
at Readable.push (node:internal/streams/readable:392:5)
at TCP.onStreamRead (node:internal/stream_base_commons:189:23)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17) {
severity_local: 'ERROR',
severity: 'ERROR',
code: '42803',
position: '609',
file: 'parse_agg.c',
line: '1438',
routine: 'check_ungrouped_columns_walker'
},
sql: `select "shared_links".*, coalesce(json_agg("a") filter(where "a"."id" is not null), '[]') as "assets", to_json("album") as "album" from "shared_links" left join lateral (select "assets".*, to_json("exifInfo") as "exifInfo" from "shared_link__asset" inner join "assets" on "assets"."id" = "shared_link__as set"."assetsId" inner join lateral (select "exif".* from "exif" where "exif"."assetId" = "assets"."id") as "exifInfo" on true where "shared_links"."id" = "shared_link__asset"."sharedLinksId" and "assets"."deletedAt" is null order by "assets"."fileCreatedAt" asc) as "a" on true left join lateral (select "albums".*, coa lesce(json_agg("assets") filter(where "assets"."id" is not null), '[]') as "assets", to_json("owner") as "owner" from "albums" left join "albums_assets_assets" on "albums_assets_assets"."albumsId" = "albums"."id" left join lateral (select "assets".*, to_json("assets_exifInfo") as "exifInfo" from "assets" inner join la teral (select "exif".* from "exif" where "exif"."assetId" = "assets"."id") as "assets_exifInfo" on true where "albums_assets_assets"."assetsId" = "assets"."id" and "assets"."deletedAt" is null order by "assets"."fileCreatedAt" asc) as "assets" on true inner join lateral (select "users".* from "users" where "users"."id " = "albums"."ownerId" and "users"."deletedAt" is null) as "owner" on true where "albums"."id" = "shared_links"."albumId" and "albums"."deletedAt" is null group by "albums"."id", "owner".*) as "album" on true where "shared_links"."id" = $1 and "shared_links"."userId" = $2 and ("shared_links"."type" = $3 or "album"."id " is not null) group by "shared_links"."id", "album".* order by "shared_links"."createdAt" desc`,
params: [
'235e724a-6687-458f-a362-354f253cae83',
'3a16b14c-1f09-4600-a890-16f3e752e14d',
'INDIVIDUAL'
]
}
[Nest] 17 - 03/25/2025, 4:31:20 PM ERROR [Api:ErrorInterceptor~28e6hwp8] Unknown error: PostgresError: column "albums.ownerId" must appear in the GROUP BY clause or be used in an aggregate function
PostgresError: column "albums.ownerId" must appear in the GROUP BY clause or be used in an aggregate function
at ErrorResponse (/usr/src/app/node_modules/postgres/cjs/src/connection.js:788:26)
at handle (/usr/src/app/node_modules/postgres/cjs/src/connection.js:474:6)
at Socket.data (/usr/src/app/node_modules/postgres/cjs/src/connection.js:315:9)
at Socket.emit (node:events:518:28)
at addChunk (node:internal/streams/readable:561:12)
at readableAddChunkPushByteMode (node:internal/streams/readable:512:3)
at Readable.push (node:internal/streams/readable:392:5)
at TCP.onStreamRead (node:internal/stream_base_commons:189:23)
at TCP.callbackTrampoline (node:internal/async_hooks:130:17)Additional information |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 4 replies
-
|
Converted to a discussion, as I cannot reproduce this. Note that we can't really provide support for the truecharts chart. |
Beta Was this translation helpful? Give feedback.
-
|
@jrasm91 Any thought on this, maybe an edge case? |
Beta Was this translation helpful? Give feedback.
-
|
After upgrading to 1.136.0 and rectifying a bunch of missing PK, FK, etc constraints, clearing out duplicates from the DB directly, etc shared links now work again 😅 Thanks again for the great software guys, and apologies since this is probably just a case of some kind of user error + weird underlying technical issue(s) |
Beta Was this translation helpful? Give feedback.

After upgrading to 1.136.0 and rectifying a bunch of missing PK, FK, etc constraints, clearing out duplicates from the DB directly, etc shared links now work again 😅
Thanks again for the great software guys, and apologies since this is probably just a case of some kind of user error + weird underlying technical issue(s)