Re: [PyGreSQL] prepared statements and adaptation

2019-05-22 Thread Christoph Zwerschke
Am 22.05.2019 um 21:00 schrieb Justin Pryzby: > It looks like this doesn't work correctly. > query_prepared sends it sargumens to postgres without adaptation. Only the query_formatted() method adapts the parameters, that's right. query() and query_prepared() pass them as strings. You need

[PyGreSQL] prepared statements and adaptation

2019-05-22 Thread Justin Pryzby
It looks like this doesn't work correctly. query_prepared sends its arguments to postgres without adaptation. For example pygres lists are sent to postgres as [1,2] rather than {1,2} to be handled as arrays, and dict(a=1) is sent as {'a': 1} rather than {"a": 1} for json. I'm not sure what the