From: Eliott <eliott100@gmail.com>
To: pgsql-odbc@postgresql.org
Subject: Access -> ODBC -> postgres
Date: Fri, 21 Apr 2006 15:22:37 +0200
Message-ID: <c2162c750604210622x15d66899n583adaff7cf24f07@mail.gmail.com> (raw)
Hi!
I am trying to create a front-end to an existing postgres database in MS
Access 2002 using 8.01.20 Unicode ODBC driver. Some of the simpler queries
were working, but as soon as I try to use a dynamic parameter, the query
sent to the server gets syntactically incorrect. I have attached some logs
to make it clear:
hdbc=151272720, stmt=151283976, result=151266488
manual_result=1, prepare=0, internal=0
bindings=0, bindings_allocated=0
parameters=151288880, parameters_allocated=1
statement_type=0, statement='SELECT
"public"."organization_user"."id","public"."bidding_auction"."id","public"."organization_company"."id"
FROM
"public"."bidding_auction","public"."organization_user","public"."organization_company"
WHERE (("public"."organization_user"."id" =
"public"."bidding_auction"."organizer_id" ) AND
(("public"."organization_user"."company_id" =
"public"."organization_company"."id" ) AND
("public"."organization_company"."id" = ? ) ) ) '
stmt_with_params='SELECT
"public"."organization_user"."id","public"."bidding_auction"."id","public"."organization_company"."id"
FROM
"public"."bidding_auction","public"."organization_user","public"."organization_company"
WHERE (("public"."organization_user"."id" =
"public"."bidding_auction"."organizer_id" ) AND
(("public"."organization_user"."company_id" =
"public"."organization_company"."id" ) AND
("public"."organization_company"."id" = 38'
data_at_exec=-1, current_exec_param=-1, put_data=0
currTuple=-1, current_col=-1, lobj_fd=-1
maxRows=0, rowset_size=1, keyset_size=0, cursor_type=0,
scroll_concurrency=1
cursor_name='SQL_CUR09046908'
----------------QResult Info
-------------------------------
fields=151266624, manual_tuples=0, backend_tuples=0,
tupleField=0, conn=0
fetch_count=0, num_total_rows=0, num_fields=0,
cursor='(NULL)'
message='(NULL)', command='(NULL)', notice='(NULL)'
status=7, inTuples=0
CONN ERROR: func=SC_execute, desc='', errnum=108, sqlstate=42601,
errmsg='ERROR: syntax error at end of input at character 396'
My settings are as follows: Disable generic optimizer on, KSQO, Parse
statements on (I experimented with toggling these with no difference)
As you can see, the stmt_with_params is missing three ')'-s from the end.
Can anybody tell me what causes this behaviour and how can I get rid of it?
Regards
Eliott
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-odbc@postgresql.org
Cc: eliott100@gmail.com
Subject: Re: Access -> ODBC -> postgres
In-Reply-To: <c2162c750604210622x15d66899n583adaff7cf24f07@mail.gmail.com>
References: <c2162c750604210622x15d66899n583adaff7cf24f07@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox