Open duncangroenewald opened 2 weeks ago
@duncangroenewald You don't need to create the statements manually on the server. PostgresNIO handles that over the wire protocol.
See these links to the implementation and a test, as an example of how to make a prepared-statement query using the PostgresClient
.
I haven't taken a proper look at the docs, so can't comment on that. We should add an example if there is no such example in the docs currently.
Thanks, I figured it out. Conceptually it is a little confusing at first so an explanation or at least a link to the test examples in the documentation would be a help.
@duncangroenewald we agree that this issue is still valid then 🙂.
The documentation doesn't appear to provide any examples of how to execute a prepared statement. The only reference I was able to find was a reference to use a struct but this seems at odds with creating prepared statements on the server and then executing them.
Is there any documentation or examples of executing a prepared statement from the client. The normal
await client.query()
doesn't appear to work.