You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I seem to be having issues trying to insert a Bool value into a bit field in MSSQL. I'm receiv'ing the following error when I execute the INSERT:
SqlError {seState = "["22018"]", seNativeError = -1, seErrorMsg = "execute execute: ["0: [Microsoft][ODBC Driver 13 for SQL Server]Invalid character value for cast specification"]"}
I have no issues reading out bit values using SELECT, although it looks like these values are being pulled into a SqlChar instead of a SqlBool so not sure if that's a clue. The SqlChar is converted to Bool on my record type, so at least it's compatible.
When I convert my record type into [SqlValue], the value for the Bool is represented as a SqlBool False instead of SqlChar '\NUL' and this fails on INSERT.
Below is some sample code that illustrates the issue:
I seem to be having issues trying to insert a
Bool
value into abit
field in MSSQL. I'm receiv'ing the following error when I execute the INSERT:I have no issues reading out bit values using SELECT, although it looks like these values are being pulled into a
SqlChar
instead of aSqlBool
so not sure if that's a clue. TheSqlChar
is converted toBool
on my record type, so at least it's compatible.When I convert my record type into
[SqlValue]
, the value for theBool
is represented as aSqlBool False
instead ofSqlChar '\NUL'
and this fails on INSERT.Below is some sample code that illustrates the issue:
The text was updated successfully, but these errors were encountered: