Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
self.param_types.len() <= (i16::MAX as usize) should change to u16::MAX #671
Comments
I have another smaller struct using the same pattern like above which succeeds.
I'm transiting from diesel-rs. In diesel I need to enable a feature called |
Oh, I debugged and found the problem. It's the PARSE command's parameter length being too long. |
So this is actually due to ambiguous documentation. We're also not the only ones to make the same mistake. The Postgres JDBC driver appears to cap the parameter count at jOOQ/jOOQ#5701 The Postgres protocol documentation specifies that the bind parameter count is an https://www.postgresql.org/docs/current/protocol-message-types.html The functions in https://www.postgresql.org/docs/current/libpq-exec.html You have to dig into the implementation to find this assertion: https://github.com/postgres/postgres/blob/7559d8ebfa11d98728e816f6b655582ce41150f3/src/interfaces/libpq/fe-exec.c#L1304 |
I'm using postgresql, sqlx="0.4.0-beta.1".
My struct is like:
My query string is like:
I'm using this method to get results:
This assertion fails:
what's the problem here?