From: | Justin Pryzby <pryzby(at)telsasoft(dot)com> |
---|---|
To: | Hassan Camacho Cadre <hccadre(at)gmail(dot)com> |
Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: How to pass a parameter in a query to postgreSQL 11 (offtopic) |
Date: | 2021-06-09 14:52:07 |
Message-ID: | 20210609145207.GX16435@telsasoft.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jun 09, 2021 at 05:30:15AM -0500, Hassan Camacho Cadre wrote:
> I recently migrated from version 8.3 of postgreSQL to v11, previously in
> all my queries for passing parameters I used the character :
> Example
> Where id =: searched
I guess you migrated to a whole new environment, with many new package
versions, not just postgres ?
We don't know how you're issuing queries, but I'm guessing some other
application is what changed.
Postgres uses $1 for query parameters, in both v8.3 and in v11.
https://www.postgresql.org/docs/8.3/libpq-exec.html
BTW, this is the list for development of postgres itself. It's much too busy
to also answer other questions. Please raise the question on the -general
list, with information about your environment.
https://www.postgresql.org/list/
Thanks,
--
Justin
> In the new version when I try to make this query it sends me an error
>
> ERROR syntax error at or near ":"
>
> Could someone help me to know how I can configure the parameter passing
> character or, failing that, how I should pass the parameters in this new
> version.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2021-06-09 14:52:38 | Re: logical replication of truncate command with trigger causes Assert |
Previous Message | David Christensen | 2021-06-09 14:32:36 | Re: DELETE CASCADE |