From debc4997119d4ee2382ed2b31a2d4e38deace1d9 Mon Sep 17 00:00:00 2001 From: Cody Robibero Date: Thu, 13 Feb 2025 20:17:25 -0700 Subject: Change BaseItemEntity ChannelId to nullable Guid --- Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs') diff --git a/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs b/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs index 632ff9307..3289484f9 100644 --- a/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs +++ b/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs @@ -678,7 +678,7 @@ public class MigrateLibraryDb : IMigrationRoutine entity.EndDate = endDate; } - if (reader.TryGetString(index++, out var guid)) + if (reader.TryGetGuid(index++, out var guid)) { entity.ChannelId = guid; } -- cgit v1.2.3 From 70b8fa73f081ba406a16ccb17bdc7c8c7a39f2b1 Mon Sep 17 00:00:00 2001 From: Roman Dordzheev Date: Sat, 8 Mar 2025 13:55:21 +0300 Subject: Include SortName in LibraryDb migration query --- Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs') diff --git a/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs b/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs index 3289484f9..e3f5b18e7 100644 --- a/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs +++ b/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs @@ -89,7 +89,7 @@ public class MigrateLibraryDb : IMigrationRoutine Audio, ExternalServiceId, IsInMixedFolder, DateLastSaved, LockedFields, Studios, Tags, TrailerTypes, OriginalTitle, PrimaryVersionId, DateLastMediaAdded, Album, LUFS, NormalizationGain, CriticRating, IsVirtualItem, SeriesName, UserDataKey, SeasonName, SeasonId, SeriesId, PresentationUniqueKey, InheritedParentalRatingValue, ExternalSeriesId, Tagline, ProviderIds, Images, ProductionLocations, ExtraIds, TotalBitrate, - ExtraType, Artists, AlbumArtists, ExternalId, SeriesPresentationUniqueKey, ShowId, OwnerId, MediaType FROM TypedBaseItems + ExtraType, Artists, AlbumArtists, ExternalId, SeriesPresentationUniqueKey, ShowId, OwnerId, MediaType, SortName FROM TypedBaseItems """; dbContext.BaseItems.ExecuteDelete(); @@ -1034,6 +1034,11 @@ public class MigrateLibraryDb : IMigrationRoutine entity.MediaType = mediaType; } + if (reader.TryGetString(index++, out var sortName)) + { + entity.SortName = sortName; + } + var baseItem = BaseItemRepository.DeserialiseBaseItem(entity, _logger, null, false); var dataKeys = baseItem.GetUserDataKeys(); userDataKeys.AddRange(dataKeys); -- cgit v1.2.3 From f1dd065eca88f6ee5a1d162587fd207da64aa679 Mon Sep 17 00:00:00 2001 From: theguymadmax Date: Mon, 10 Mar 2025 11:50:28 -0400 Subject: Include CleanName in LibraryDb migration query --- Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs') diff --git a/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs b/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs index e3f5b18e7..dfe497c49 100644 --- a/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs +++ b/Jellyfin.Server/Migrations/Routines/MigrateLibraryDb.cs @@ -89,7 +89,7 @@ public class MigrateLibraryDb : IMigrationRoutine Audio, ExternalServiceId, IsInMixedFolder, DateLastSaved, LockedFields, Studios, Tags, TrailerTypes, OriginalTitle, PrimaryVersionId, DateLastMediaAdded, Album, LUFS, NormalizationGain, CriticRating, IsVirtualItem, SeriesName, UserDataKey, SeasonName, SeasonId, SeriesId, PresentationUniqueKey, InheritedParentalRatingValue, ExternalSeriesId, Tagline, ProviderIds, Images, ProductionLocations, ExtraIds, TotalBitrate, - ExtraType, Artists, AlbumArtists, ExternalId, SeriesPresentationUniqueKey, ShowId, OwnerId, MediaType, SortName FROM TypedBaseItems + ExtraType, Artists, AlbumArtists, ExternalId, SeriesPresentationUniqueKey, ShowId, OwnerId, MediaType, SortName, CleanName FROM TypedBaseItems """; dbContext.BaseItems.ExecuteDelete(); @@ -1039,6 +1039,11 @@ public class MigrateLibraryDb : IMigrationRoutine entity.SortName = sortName; } + if (reader.TryGetString(index++, out var cleanName)) + { + entity.CleanName = cleanName; + } + var baseItem = BaseItemRepository.DeserialiseBaseItem(entity, _logger, null, false); var dataKeys = baseItem.GetUserDataKeys(); userDataKeys.AddRange(dataKeys); -- cgit v1.2.3