[Zope] bug with SQL methods?

Jordan B. Baker jbb@spyderlab.com
Fri, 5 Mar 1999 14:45:11 -0500 (EST)


Hi, I'm re-posting to this list because it probably is more suited here...

thanks in advance,

-------
Jordan B. Baker -- jbb@spyderlab.com
weaving the web @ http://www.spyderlab.com


---------- Forwarded message ----------
Date: Fri, 5 Mar 1999 12:11:02 -0500 (EST)
From: Jordan B. Baker <jbb@spyderlab.com>
To: zope-dev@zope.org
Subject: [Zope-dev] SQL methods q:

Hi guys:

I'm trying to write a SQL method though, and its giving me an error when I
try to test it..

Error, exceptions.TypeError: keyword parameter redefined
SQL used:
Could not render the query template!

The query I was using:

SELECT searches.engineID as engine,
 queries.param as query,
 MAX(searches.timestamp) AS time,
 searches.position AS position,
 MIN(lastsearch.timestamp) AS lastupdate,
 lastsearch.position AS lastsearch,
 searches.URL as URL,
 'NA' as change,
 engines.graphic as engine_gfx
FROM searches LEFT JOIN searches as lastsearch USING (queryID,engineID), engines, queries
WHERE lastsearch.timestamp BETWEEN <!--#sqlvar pstart type=int --> AND <!--#sqlvar pend type=int -->
AND searches.timestamp BETWEEN <!--#sqlvar pstart type=int --> AND <!--#sqlvar pend type=int -->
AND queries.clientID = <!--#sqlvar client type=int -->
AND queries.queryID = searches.queryID
AND engines.engineID = searches.engineID
AND searches.timestamp != lastsearch.timestamp
GROUP BY searches.engineID, searches.queryID
ORDER BY searches.engineID ASC, searches.queryID ASC, searches.timestamp ASC, lastsearch.timestamp DESC
;

Any ideas what I could be doing wrong?

BTW, Zope is great! I've been kinda messing around with it for a while,
also checking out PHP3 and other UNIX-based scripting languages and I've
very impressed.  As soon as I figure out what is causing this I plan to
write something 'cool' with Zope :)

TIA,

-jordan.


_______________________________________________
Zope-Dev maillist  -  Zope-Dev@zope.org
http://www.zope.org/mailman/listinfo/zope-dev