> >Diny, why do you need to execute multiple selects in one SQL-Method?
> >
> Belief me, you don't want to know ;)
> I'm building a database application for the drugstore department.
> Veterinarians can find medicines by searching on animal, ingredients,
> diseases etc. When they've found one medicine all the detailed information
> about this particular medicine is being displayed. At this point i thought
> i could use the multiple selects.
> The medicine has a 1 to many relationship with animals, ingredients,
> diseases etc. all stored in different tables. When i use one single select
> statement with several where conditions, and one relationship isn't filled,
> the query returns nothing at all.
> >Maybe there is another way of doing it?
> >
> I'll split up one complex ZSQL method into several simple methods.

Without seeing your queries, I would say use sql's UNION command, eg,

SELECT name FROM animals WHERE id =21 UNION SELECT name FROM diseases WHERE id

regards, Ivan

Zope maillist  -  [EMAIL PROTECTED]
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to