Fetching query result problem - Mailing list psycopg

From Jacek Kałucki
Subject Fetching query result problem
Date
Msg-id 4F141DC0.3040009@rz.onet.pl
Whole thread Raw
Responses Re: Fetching query result problem  (Daniele Varrazzo <daniele.varrazzo@gmail.com>)
List psycopg
Hi.

I have a problem with some query.
When I issue it from within postgresql console, it returns correct rows count as a result,
but when executed within psycopg2 cursor.execute() row count differs.
In first situation I get 5 rows versus 3 at second time.
This is my query:
select "inventory_line"."iid" as "iid",
         "inventory_line"."il_depot_id" as "il_depot_id",
         "inventory_line"."il_expiry_date" as "il_expiry_date",
         "inventory_line"."il_info" as "il_info",
         "inventory_line"."il_location_x_id" as "il_location_x_id",
         "inventory_line"."il_location_y_id" as "il_location_y_id",
         "inventory_line"."il_location_z_id" as "il_location_z_id",
         "inventory_line"."il_lot_no" as "il_lot_no",
         "inventory_line"."il_package_id" as "il_package_id",
         "inventory_line"."il_pass_id" as "il_pass_id",
         "inventory_line"."il_product_id" as "il_product_id",
         "inventory_line"."il_production_date" as "il_production_date",
         "inventory_line"."il_quantity" as "il_quantity",
         "inventory_line"."il_quantity_spare" as "il_quantity_spare",
         "inventory"."in_close_date" as "in_close_date",
         "inventory"."in_inventory_name" as "in_inventory_name"
     from "inventory_line"
     inner join "inventory_pass" on "inventory_pass"."iid" = "inventory_line"."il_pass_id"
     inner join "inventory" on "inventory"."iid" = "inventory_pass"."ip_inventory_id"
     where "inventory_line"."il_product_id" = 6326 and "inventory"."in_branch_id" = 1 limit 100

Could you give me any suggestions how to figure the reason out?

--
Regards
Jacek Kałucki


psycopg by date:

Previous
From: Jason Erickson
Date:
Subject: Re: after application close MS Visual C++ runtime library error occurs
Next
From: Daniele Varrazzo
Date:
Subject: Re: Fetching query result problem