The following query is generated by a PHP script:

select contacts.first_name, contacts.middle_name, contacts.last_name, addresses.h_city, contacts.email1 from contacts, addresses, contacts_addresses, trips, contacts_trips where trips.premium > 100 and trips.premium < 201 and contacts.id=contacts_addresses.contact_id and contacts_addresses.address_id=addresses.id and contacts.id=contacts_trips.contact_id and contacts_trips.trip_id=trips.id

There are around 14,000 records in the database (Apache-PHP-MySQL combo installed on my computer). Since it was freezing the browser, I copy-pasted the generated query in MySQL-Front. After more than a minute (I was going to end the program using Task Manager) it returned around 10,000+ records. Why is it taking so long. Is there something logically wrong in the query.

Thanks
Amrit


____ • The WDVL Discussion List from WDVL.COM • ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] or
use the web interface http://e-newsletters.internet.com/discussionlists.html/
      Send Your Posts To: [email protected]
To change subscription settings, add a password or view the web interface:
http://intm-dl.sparklist.com/read/?forum=wdvltalk

________________  http://www.wdvl.com  _______________________

You are currently subscribed to wdvltalk as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016

Please include the email address which you have been contacted with.

Reply via email to