View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0008388 | VALENTINA STUDIO | Tool - SQL Editor | public | 2018-10-11 14:40 | 2019-09-25 06:38 |
Reporter | Carlos Fuentes | Assigned To | Sergey Pashkov | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Platform | INTEL | OS | Mac OS | OS Version | 10.14 |
Product Version | 8.6.x | ||||
Target Version | 9.6.x | Fixed in Version | 9.6.x | ||
Summary | 0008388: Parameters not working for Postgresql on 8.6.1 | ||||
Description | Just downloaded version 8.6.1 and attempted to run a simple query with parameters and got an error. | ||||
Steps To Reproduce | Run query with parameter placeholder "?", set value if needed in parameters sections with "Use Parameters" turned on. Query fails. Replace parameter placeholder with value and query works. See screenshot. | ||||
Tags | No tags attached. | ||||
Working with DB: | postgreSQL Server | ||||
Version of your DB | 9.6.6 | ||||
2018-10-11_10-23-21.png (65,196 bytes) |
|
Well I just realized my problem. It seems that bind variables are represented by $ followed by a number in postgresql. And that works just fine (thank you BTW - love this feature). If I can I'd love to change this to a feature request: could we have a dropdown to automatically convert between bind variable syntax. This will allow users to use a query with bind variables on a different DB and also if the dropdown defaults to the syntax for the current DB it would help the user know what the right syntax is. This will also help users (like me) when they have a SQL statement dumped from code that is parameterized with "?" and let them easily convert it to the appropriate bind variable syntax. Before I had to go ? by ? and replace it with an appropriate value to test a query that was giving me trouble in our application. |
|
Hello Carlos, Unnamed '?' parameters were supposed to work, too, they are prepared the same way, I'll figure out why they are not applied. |
|
Looks like libpq library doesn't support '?' parameters https://www.postgresql.org/docs/current/static/libpq-exec.html What client do you use? Maybe it implements '?' parameters on its own. Anyway, conversion within the application would be helpful. |
|
Now unnamed parameters are supported for all databases, including PostgreSQL | |
Let me add -- Valentina Studio 9.6 on the fly replace ? to syntax which PostgreSQL understands. | |
Date Modified | Username | Field | Change |
---|---|---|---|
2018-10-11 14:40 | Carlos Fuentes | New Issue | |
2018-10-11 14:40 | Carlos Fuentes | File Added: 2018-10-11_10-23-21.png | |
2018-10-11 14:42 | Sergey Pashkov | Assigned To | => Sergey Pashkov |
2018-10-11 14:42 | Sergey Pashkov | Status | new => assigned |
2018-10-11 14:57 | Carlos Fuentes | Note Added: 0010506 | |
2018-10-11 19:21 | Sergey Pashkov | Note Added: 0010507 | |
2018-10-12 08:28 | Sergey Pashkov | Note Added: 0010508 | |
2019-09-24 19:53 | Sergey Pashkov | Status | assigned => resolved |
2019-09-24 19:53 | Sergey Pashkov | Resolution | open => fixed |
2019-09-24 19:53 | Sergey Pashkov | Product Version | => 8.6.x |
2019-09-24 19:53 | Sergey Pashkov | Fixed in Version | => 9.6.x |
2019-09-24 19:53 | Sergey Pashkov | Target Version | => 9.6.x |
2019-09-24 19:53 | Sergey Pashkov | Note Added: 0010992 | |
2019-09-25 06:38 | Ruslan Zasukhin | Note Added: 0010994 |