| From: | Julien Rouhaud <julien(dot)rouhaud(at)dalibo(dot)com> |
|---|---|
| To: | pgsql-hackers(at)postgresql(dot)org |
| Subject: | Preserving param location |
| Date: | 2017-03-11 22:09:32 |
| Message-ID: | [email protected] |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Hello,
When a query contains parameters, the original param node contains the token
location. However, this information is lost when the Const node is generated,
this one will only contain position -1 (unknown).
FWIW, we do have a use case for this (custom extension that tracks quals
statistics, which among other thing is used to regenerate query string from a
pgss normalized query, thus needing the original param location).
Is this something we want to get fixed? If yes, attached is a simple patch for
that.
Regards.
--
Julien Rouhaud
http://dalibo.com - http://dalibo.org
| Attachment | Content-Type | Size |
|---|---|---|
| fix_param_location-1.diff | text/plain | 996 bytes |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andres Freund | 2017-03-11 22:17:42 | Re: Need a builtin way to run all tests faster manner |
| Previous Message | Eric Ridge | 2017-03-11 21:58:00 | Re: How to get the 'ctid' from a record type? |