Dan Hansen wrote:
> is essentially giving me what I need:
>
> CREATE TEMPORARY TABLE temptable
> SELECT state.name AS state , group.name AS group,
> group.zip AS zip, city.name AS city
> FROM city, group, zip
> LEFT JOIN state ON city.state_id = state.id
> WHERE group.zip = zip.zip
> AND zip.city_
For everyone who helped, THANK YOU!!
For anyone who might be interested, here's what finally did the trick and
is essentially giving me what I need:
CREATE TEMPORARY TABLE temptable
SELECT state.name AS state , group.name AS group,
group.zip AS zip, city.name AS city
FROM city, group, zip
LEFT J
* D. R. Hansen
> At 03:51 AM 10/15/03, Diana Soares wrote:
> >You're confusing the left/right "sides" of LEFT JOIN...
> >Using LEFT JOIN, it is the right table that is dependent on the left
> >table. All results from left table are selected.
> >So you may try:
[...]
> I believe I tried that -- but
I believe I tried that -- but when I did (and I just repeated it with the
same result) mysql effectively hangs (i.e. the query takes interminably
long -- I let it run for 20 minutes before killing it).
So should I be looking at an indexing issue? Right now the only things
indexed in the tables
You're confusing the left/right "sides" of LEFT JOIN...
Using LEFT JOIN, it is the right table that is dependent on the left
table. All results from left table are selected.
So you may try:
SELECT state.name AS state , group.name AS group,
group.zip AS zip, city.name as city
FROM state
LEF
Uberdumb question - but I'm still enough of a newbie that this is giving
me fits...
I have four tables, with relevant columns as follows:
++ ++
group zip
-- --
name varchar city_id int
zip mediumint zip mediumint