Re: [Zope] Multiple queries in a ZSQL method (MySQLda)
Is there a workaround to have those 2 SQL queries in one ZSQL method ? I use this thing: <dtml-var sql_delimiter>
I see no other purpose for it than abstracting from ';', (but i don't know if this works in your configuration) Met vriendelijke groeten, Hans de Wit Stichting Farmaceutische Kengetallen Postbus 30460 2500 GL DEN HAAG Tel. 070-3737448 Fax 070-3737445
Greetings, As Hans mentions, you use the <dtml-var sql_delimiter> (&dtml-sql_delimiter;) construction for multiple statements in a single ZSQL method. But concerning multiple queries (selects), AFAIK, this is limited in SQL to 1 per statement... Unless you use more complicated SQL like select into or using a nested select inside brackets. Cheers, Paul Zwarts -----Original Message----- From: zope-admin@zope.org [mailto:zope-admin@zope.org] On Behalf Of H.de.Wit@SFK.NL Sent: Tuesday, November 27, 2001 3:35 PM To: zope@zope.org Subject: Re: [Zope] Multiple queries in a ZSQL method (MySQLda)
Is there a workaround to have those 2 SQL queries in one ZSQL method ? I use this thing: <dtml-var sql_delimiter>
I see no other purpose for it than abstracting from ';', (but i don't know if this works in your configuration) Met vriendelijke groeten, Hans de Wit Stichting Farmaceutische Kengetallen Postbus 30460 2500 GL DEN HAAG Tel. 070-3737448 Fax 070-3737445 _______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Many thanks Hans and Paul. "<dtml-var sql_delimiter>" works perfectly. Just it was not on my Zope book (the French one). I needed multiple "insert" in the database. Of course, multiple select has no sense ;-) --Gilles ----- Original Message ----- From: "Paul Zwarts" <paz@oratrix.com> To: "'Gilles Lenfant'" <glenfant@bigfoot.com> Cc: <H.de.Wit@SFK.NL>; <zope@zope.org> Sent: Tuesday, November 27, 2001 4:17 PM Subject: RE: [Zope] Multiple queries in a ZSQL method (MySQLda)
Greetings,
As Hans mentions, you use the <dtml-var sql_delimiter> (&dtml-sql_delimiter;) construction for multiple statements in a single ZSQL method. But concerning multiple queries (selects), AFAIK, this is limited in SQL to 1 per statement... Unless you use more complicated SQL like select into or using a nested select inside brackets.
Cheers, Paul Zwarts
participants (3)
-
Gilles Lenfant -
H.de.Wit@SFK.NL -
Paul Zwarts