Postgresql & Oracle Heteregenous services - strange behaviour

From: Marcin Stępnicki <mstepnicki(at)gmail(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Postgresql & Oracle Heteregenous services - strange behaviour
Date: 2007-01-17 12:52:25
Message-ID: pan.2007.01.17.12.52.25.379331@gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-sql

I'm not sure if it's proper group, if not then please direct me to more
appropriate one (unixodbc?)

I've set up connection from oracle to postgresql via unixodbc and oracle's
heterogeneus services. The connection works, but when I issue the
following:

select "p_nr_pesel" from "zew_patients"@my_postgresql where
"p_patient_id"=19300;

I see this in postgresql logs:

[6210] DEBUG: query: select * from "zew_patients"
[6210] DEBUG: query: SELECT "A1"."p_nr_pesel" FROM "zew_patients"
"A1" WHERE ("A1"."p_patient_id" = 19300)

The point is, I don't why oh why the first select is issued (some cache?),
but it slows the query a lot for obvious reasons. When I issue it for the
second time in the same session, I see only the second select (that's how
it should be from my point of view). After reconnecting I see both selects
again :(.

If it's known issue, I'd be grateful even for simple RTFM and a link :).

Thank you for your time,
Marcin

--
| And Do What You Will be the challenge | http://apcoln.linuxpl.org
| So be it in love that harms none | http://biznes.linux.pl
| For this is the only commandment. | http://www.juanperon.info
`---* JID: Aragorn_Vime(at)jabber(dot)org *---' http://www.naszedzieci.org

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Andrew Sullivan 2007-01-17 12:55:11 Re: Update query by joining multiple tables.
Previous Message Moiz Kothari 2007-01-17 11:20:18 Update query by joining multiple tables.