[Zope] ZPygreSQL woes
TFE MMS JARVIS JOHN
jarvis.sd082@ex.tel.co.jp
Tue, 27 Jul 1999 10:56:05 +0900
oh...
This query outright crashes Zope on my system!
PostgreSQL 6.5
Vine linux 1.1 (Japanese Red Hat clone)
Linux 2.2.9 (with appropriate updates :^)
Python 1.5.1
Zope 1.10.3
ZPyGreSQLDA 0.3
I noticed that if you take out both MONEY types from the query, Zope
doesn't crash. If you take out one, Zope doesn't crash, but only returns
one row. It sure looks like a ZPyGreSQLDA bug.
I've never had any other problems like this.
pcgi.log entry:
--------------------
Tue Jul 27 10:39:22 1999
pcgi-wrapper: unexpected out-of-bound data in stdin t[0] = 80
queries:
-----------
vvvvvvvvvvvvvvv
CRASHES:
^^^^^^^^^^^^^^^
select prodname,
description,
retailprice,
prodVis,
IMpartNumber,
size,
speed ,
color,
weight ,
height ,
width ,
onhand ,
reorder ,
discontinued ,
supplier ,
supplierPartNumber ,
manufacturer,
cost
from items
====
select retailprice, cost from items
------------------------------
Returns only one row:
------------------------------
select prodname,
description,
prodVis,
IMpartNumber,
size,
speed ,
color,
weight ,
height ,
width ,
onhand ,
reorder ,
discontinued ,
supplier ,
supplierPartNumber ,
manufacturer,
cost
from items
====
select retailprice from items
====
select cost from items
------------------------
Returns all rows:
------------------------
select prodname,
description,
prodVis,
IMpartNumber,
size,
speed ,
color,
weight ,
height ,
width ,
onhand ,
reorder ,
discontinued ,
supplier ,
supplierPartNumber ,
manufacturer
from items
--
John Jarvis
> -----Original Message-----
> From: nathan frund [SMTP:ndf@rocketmail.com]
> Sent: Tuesday, July 27, 1999 2:04 AM
> To: Hannu Krosing
> Cc: zope@zope.org
> Subject: Re: [Zope] ZPygreSQL woes
>
>
> ---Hannu Krosing <hannu@trust.ee> wrote:
> >
> > ndf@rocketmail.com wrote:
> > >
> > > I've run into a problem with Zope with
> PostgreSQL. The query runs and
> > > runs and runs till all the memory on the server
> is used up and Zope
> > > falls over.
> >
> > I'm using it all the time with no major problems.
> >
> > Do the same queries run fine from psql ?
>
>
>
> Yea, even from from 'regular old Python' and with
> PGaccess.
>
> Here is the SQL that I used to create the table.
> -------------------------------
> items.sql
> -------------------------------
> CREATE TABLE items (
> prodname char(20),
> retailPrice money,
> description char(80),
> prodVis char(80),
> IMpartNumber char(20),
> size float4,
> speed float4,
> color char(8),
> weight int8,
> height int8,
> width int8,
> onhand int8,
> reorder int8,
> discontinued boolean,
> supplier char(20),
> supplierPartNumber char(20),
> manufacturer char(16),
> cost money
> );
>
>
> copy items from stdin using delimiters ',';
> "15"" 5VX 28mm",0,0,0,0,0,0,0,0,0,0,0,0,0,0,9004520,0,200
> "17"" 7SP .28mm 1280x1024(1yrs warr)",0,0,0,0,0,0,0,0,0,0,0,0,0,0,9004190,
> 0,250
> "17"" 70+ .28mm 1280x1024",0,0,0,0,0,0,0,0,0,0,0,0,0,0,9004120,0,300
> -----------------------------------------------------
>
> psql database < items.sql
>
>
>
> Python code that works.
> ------------------------------------------
>
> from pg import *
>
> cnx=connect('database','localhost',5432)
>
> query=cnx.query('select * from items')
> print "\n"
>
> fields=query.listfields()
> print fields
>
> ------------------------------------------
>
>
> > Schemas, row counts, queries executed ?
>
>
> The query with Zope is the same exact query with the
> python... "Select * from items"
>
>
> It stops even with only three rows in the database.
> The SQL above for me stops Zope and Postgres in their
> tracks.
>
>
> > Also OS, postgres and ZPygreSQLDA versions.
>
>
> I'm running Red Hat Linux 5.2 with kernel 2.2.9
> Python 1.5.2 from Oliver Andrich's site.
> Postgres is version 6.4.2-5.
> ZPyGreSQLDA version is 0.3.
> Zope 2.0.0b1 and Zope 1.10.3
>
> I also have python-PyGreSQL-2.3.2.rpm installed. I
> got it from rufus.w3.org. I removed it thinking that
> it conflicted or caused the problem. But removing it
> didn't seem to help so I reinstalled the package.
>
>
> I haven't tried yet but I'm going to write an
> external method and see if that works.
>
>
> I've put up a lot of info, thanks for your help.
> _________________________________________________________
> DO YOU YAHOO!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>
>
> _______________________________________________
> Zope maillist - Zope@zope.org
> http://www.zope.org/mailman/listinfo/zope
>
> (To receive general Zope announcements, see:
> http://www.zope.org/mailman/listinfo/zope-announce
>
> For developer-specific issues, zope-dev@zope.org -
> http://www.zope.org/mailman/listinfo/zope-dev )