[Zope] SQL: nested select

Bryan C. Andregg bryan.andregg@duke.edu
Mon, 19 Aug 2002 13:17:48 -0400


--ofQ+NWZjH2FySEVi
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Aug 19, 2002 at 12:47:50PM -0400, vsbabu@vsbabu.org mailed:
> Hi,
>=20
> Wouldn't this work?
>
>   select * from models
>     <dtml-sqlgroup where>
>       <dtml-sqltest foo type=3Dnb optional>
>     <dtml-and>
>       <dtml-sqltest bar type=3Dnb optional>
>     <dtml-and>
>       name =3D (select name from users where
>       uid =3D <dtml-sqlvar uid type=3Dint )
>     </dtml-sqlgroup>

This make "name" a required field or matches on '' which fails, of course.
--=20
Bryan C. Andregg		Duke University Medical Center
 Programmer			Dept. of Anesthesiology
 e <bryan.andregg@duke.edu>
 p +1 919 684 6201

--ofQ+NWZjH2FySEVi
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE9YSg8j9pElyS/cakRAqjtAJ4qUYPBd9IhZRrZRsBTYcy0awty4QCfSI4C
aIoMhYUzWHML7V4g8b5JMpM=
=GqBC
-----END PGP SIGNATURE-----

--ofQ+NWZjH2FySEVi--