diff --git a/CHANGELOG.md b/CHANGELOG.md index 262a3bb8..973e3023 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,8 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ## [Unreleased] +### Fixed +- Fix startup error with MySql backend caused by database cleaner ## [0.8.8-beta] - 2024-09-19 ### Added diff --git a/ErsatzTV/Services/RunOnce/DatabaseCleanerService.cs b/ErsatzTV/Services/RunOnce/DatabaseCleanerService.cs index 79d6f1f2..57930d1c 100644 --- a/ErsatzTV/Services/RunOnce/DatabaseCleanerService.cs +++ b/ErsatzTV/Services/RunOnce/DatabaseCleanerService.cs @@ -45,16 +45,16 @@ public class DatabaseCleanerService( await dbContext.Connection.ExecuteAsync( """ delete - from MediaItem - where Id not in (select Id from Movie) - and Id not in (select Id from Show) - and Id not in (select Id from Season) - and Id not in (select Id from Episode) - and Id not in (select Id from OtherVideo) - and Id not in (select Id from MusicVideo) - and Id not in (select Id from Song) - and Id not in (select Id from Artist) - and Id not in (select Id from Image) + from `MediaItem` + where Id not in (select Id from `Movie`) + and Id not in (select Id from `Show`) + and Id not in (select Id from `Season`) + and Id not in (select Id from `Episode`) + and Id not in (select Id from `OtherVideo`) + and Id not in (select Id from `MusicVideo`) + and Id not in (select Id from `Song`) + and Id not in (select Id from `Artist`) + and Id not in (select Id from `Image`) """); }