Skip to content

UpdateFromQuery generating invalid SQL update command for SQLite #615

@vikas0sharma

Description

@vikas0sharma

Description

I encountered an issue with the UpdateFromQuery method generating an invalid SQL update command when using SQLite.

Exception

Exception message:
Stack trace:
Unhandled exception. Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 1: 'incomplete input'.
   at Microsoft.Data.Sqlite.SqliteException.ThrowExceptionForRC(Int32 rc, sqlite3 db)
   at Microsoft.Data.Sqlite.SqliteCommand.PrepareAndEnumerateStatements()+MoveNext()
   at Microsoft.Data.Sqlite.SqliteCommand.GetStatements()+MoveNext()
   at Microsoft.Data.Sqlite.SqliteDataReader.NextResult()
   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior)
   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader()
   at Microsoft.Data.Sqlite.SqliteCommand.ExecuteNonQuery()
   at Z.EntityFramework.Extensions.BatchUpdate.<>c.(DbCommand , Nullable`1 )
   at Z.EntityFramework.Extensions.BatchUpdate.ExecuteT
   at BatchUpdateExtensions.UpdateFromQueryT
   at BatchUpdateExtensions.UpdateFromQueryT
   at Program.Main()

Fiddle or Project (Optional)

Fiddle that reproduces the issue: https://dotnetfiddle.net/NZ1fWA

Further technical details

  • EF version: [EF Core v8.0.7]
  • EF Extensions version: [EFE Core v8.103.1]
  • Database : [SQLite ]
  • Database Provider version (NuGet): [Microsoft.Data.SqlClient v5.1.2]

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions