Re: Inner Join or 2nd Query...?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mark Rees wrote:

Hi All,

with wanting to show both product types(Switch, Router etc) and Makers(Cisco, Avaya, etc) on the one page in select boxes, I was wondering, do you use 2 seperate queries to the database or do you inner

join to get all in 1..? I have set up different tables with related id's

etc. So, to get Products.product_name and Products.product_id along with

what the below query pulls, what wold be best..? I believe if I do a 2nd

query, than some variables need to be identified with the particular query, yes..? Cheers.
----------------------------------------
What is your question in one sentence?


Is it "how do I do an inner join"?


I guess I was looking for people's opinions, not a specific answer, I think...

Is it "are two separate queries on two tables faster than one query on
both tables"?


Well, again, no not really. I guess I was curious how others do things.

Or something else entirely?


Could be. Sorry, perhaps I'm thinking too general with this, yes..? Cheers.

Mark Sargent.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux