[Zope-DB] select max()

Andre Meyer a.meyer at hccnet.nl
Thu Oct 16 14:49:14 EDT 2003


Thanks for your response.

I am using Gadfly for the moment to experiment with SQL in Zope. Later I
want to use MySQL, because I want to be able to make backups of the db.

Would you suggest to use the object db of Zope ZODB instead? How can it be
backed up? Can I access it from Python programs? I need to write a Python
program to import (maybe export) from Excel.

I solved my problem after a lot of experimenting (see below). The web-based
interface is a real pain in the a.. for developing. Can an external editor
be used?

thanks and kind regards
Andre


solution:
<dtml-let id="max_composer_id()[0][0] +1">
insert into composer
  values(
    <dtml-sqlvar id type="int">,
    ...
</dtml-let>


----- Original Message -----
From: "Bo M. Maryniuck" <b.maryniuk at forbis.lt>
To: "Andre Meyer" <a.meyer at hccnet.nl>; <zope-db at zope.org>
Sent: Thursday, October 16, 2003 7:30 PM
Subject: Re: [Zope-DB] select max()


> On Thursday 16 October 2003 17:56, Andre Meyer wrote:
> > Dear Gadfly specialists
> >
> > While trying to build a simple music database I have the following
problem:
>
> [...]
>
> First of all: if Gadfly is enough for you needs, therefore you really
don't
> want use it. Because you can do everything (and much better) in pure ZODB
> with objects and BTreeFolder2 or even OrderedFolder or even simple Folder.
> Gadfly is to teach very young children what SQL principle is.
>
> Second: NEVER-NEVER-NEVER use "*" (asterisk) SQL's to select stuff from
ANY of
> exiting DB over the Earth. This is very bad.
>
> Third: you probably want to define types, like:  "foo:string", "bar:int"
etc
> in your template. Zope Book at zope.org is your friend.
>
> --
> Regards, Bogdan
>
> A computer without any MS Windows is like a fish without a bicycle.
> -- With apologies to Gloria Steinem
>




More information about the Zope-DB mailing list