We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When calling ExecuteScalarAsync for a nullable integer, there's a few possible scenarios I can think of:
When the following is done: (this can also happen if you select data which is null, or when an aggregate contains no rows)
await database.ExecuteScalarAsync<int?>(Sql.Builder.Select("NULL"))
This generates an exception:
A first chance exception of type 'System.InvalidCastException' occurred in mscorlib.dll
Additional information: Object cannot be cast from DBNull to other types.
The text was updated successfully, but these errors were encountered:
I suspect this change needs to be back-ported: CollaboratingPlatypus#280
I'll see if I can tackle this soon.
Sorry, something went wrong.
#26 - bug with ExecuteScalarAsync + nullable
88a7dd6
fixed and will be released shortly with 1.2
released https://www.nuget.org/packages/AsyncPoco/1.2.0
No branches or pull requests
When calling ExecuteScalarAsync for a nullable integer, there's a few possible scenarios I can think of:
When the following is done: (this can also happen if you select data which is null, or when an aggregate contains no rows)
This generates an exception:
A first chance exception of type 'System.InvalidCastException' occurred in mscorlib.dll
Additional information: Object cannot be cast from DBNull to other types.
The text was updated successfully, but these errors were encountered: