diff -r 4abf603ec3e6 -r 6284a24658d6 engine/src/ShowEngine.cpp --- a/engine/src/ShowEngine.cpp Thu Apr 29 14:23:30 2010 +0100 +++ b/engine/src/ShowEngine.cpp Sat May 01 21:56:59 2010 +0100 @@ -683,8 +683,7 @@ // 2. select the first MaxListItems shows // 3. delete the rest if downloadstate is ENotDownloaded - _LIT(KSqlStatement,"delete from shows where feeduid=%u and downloadstate=0 and uid not in " \ - "(select uid from shows where feeduid=%u order by pubdate desc limit %u)"); + _LIT(KSqlStatement,"delete from shows where feeduid=%u and downloadstate=0 and uid not in (select uid from shows where feeduid=%u order by pubdate desc limit %u)"); iSqlBuffer.Format(KSqlStatement, aFeedUid, aFeedUid, iPodcastModel.SettingsEngine().MaxListItems()); sqlite3_stmt *st; @@ -786,8 +785,7 @@ descPtr.Copy(aItem.Description()); PodcastUtils::SQLEncode(descPtr); - _LIT(KSqlStatement, "insert into shows (url, title, description, filename, position, playtime, playstate, downloadstate, feeduid, uid, showsize, trackno, pubdate, showtype)" - " values (\"%S\",\"%S\", \"%S\", \"%S\", \"%Lu\", \"%u\", \"%u\", \"%u\", \"%u\", \"%u\", \"%u\", \"%u\", \"%Lu\", \"%d\")"); + _LIT(KSqlStatement, "insert into shows (url, title, description, filename, position, playtime, playstate, downloadstate, feeduid, uid, showsize, trackno, pubdate, showtype) values (\"%S\",\"%S\", \"%S\", \"%S\", \"%Lu\", \"%u\", \"%u\", \"%u\", \"%u\", \"%u\", \"%u\", \"%u\", \"%Lu\", \"%d\")"); iSqlBuffer.Format(KSqlStatement, &aItem.Url(), &titlePtr, &descPtr, &aItem.FileName(), aItem.Position().Int64(), aItem.PlayTime(), @@ -860,9 +858,7 @@ descPtr.Copy(aItem.Description()); PodcastUtils::SQLEncode(descPtr); - _LIT(KSqlStatement, "update shows set url=\"%S\", title=\"%S\", description=\"%S\", filename=\"%S\", position=\"%Lu\"," - "playtime=\"%u\", playstate=\"%u\", downloadstate=\"%u\", feeduid=\"%u\", showsize=\"%u\", trackno=\"%u\"," - "pubdate=\"%Lu\", showtype=\"%d\", lasterror=\"%d\" where uid=\"%u\""); + _LIT(KSqlStatement, "update shows set url=\"%S\", title=\"%S\", description=\"%S\", filename=\"%S\", position=\"%Lu\" playtime=\"%u\", playstate=\"%u\", downloadstate=\"%u\", feeduid=\"%u\", showsize=\"%u\", trackno=\"%u\",pubdate=\"%Lu\", showtype=\"%d\", lasterror=\"%d\" where uid=\"%u\""); iSqlBuffer.Format(KSqlStatement, &aItem.Url(), &titlePtr, &descPtr, &aItem.FileName(), aItem.Position().Int64(), aItem.PlayTime(), aItem.PlayState(), aItem.DownloadState(), aItem.FeedUid(),