Hi,

So long as there is some way of joining your two tables, this shouldn't be a
problem:

SELECT name FROM mytable, myothertable WHERE (mytable.ID =
myothertable.idlistcolumn);

Regards

Quentin

-----Original Message-----
From: John Coggeshall [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 28 February 2001 2:45 p.m.
To: [EMAIL PROTECTED]
Subject: Complex Query Problems



I've got a complex query... I was wondering if someone could give me some
advice..

Is there any way that I can base the WHERE clause of a query on the contents
of another table?? for instance...

SELECT name FROM mytable WHERE(ID=myothertable.idlistcolumn);

where myothertable is a HEAP constructed just prior to the above query?

If so, is this a reasonable method? If not, Any suggestions?

John

John Coggeshall
[EMAIL PROTECTED]

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Read my Biweekly Column on O'Reilly's ONLamp.com "PHP Foundations" and my
weekly Zend.com Code Gallery Column "In The Spotlight" Also be sure to visit
www.coggeshall.org!


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail
<[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended 
recipient, you are asked to respect that confidentiality and not 
disclose, copy or make use of its contents. If received in error 
you are asked to destroy this email and contact the sender immediately. 
Your assistance is appreciated.

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to