Error! Writing values of 'System.UInt16' is not supported for parameters having no NpgsqlDbType or DataTypeName. Try setting one of these values to the expected database type.. #1892
Closed
PeterKnotek
started this conversation in
General
Replies: 1 comment 2 replies
-
|
Thanks for the feedback. I have just now updated the app to fix the issue. Do update the app to v1.2 and let me know your feedback. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
App: QueryLogsPostgreSqlApp v1.0
Database: PostgreSQL 17.9
Issue: Filtering DNS logs by Type, RCODE, Protocol, or Class fails
DESCRIPTION:
ERROR MESSAGE:
"Error! Writing values of 'System.UInt16' is not supported for parameters
having no NpgsqlDbType or DataTypeName. Try setting one of these values
to the expected database type."
ROOT CAUSE:
When filtering logs via Web UI, the app converts filter values to SQL
parameters but does not properly set NpgsqlDbType on the parameters.
The PostgreSQL driver cannot determine the parameter type (UInt16 vs Integer)
and throws an error.
EXPECTED:
Parameters should be mapped with NpgsqlDbType.Integer to ensure proper
type conversion for PostgreSQL.
STEPS TO REPRODUCE:
Beta Was this translation helpful? Give feedback.
All reactions