Leech (?) content of mySQL tables
From: knoak (knoakske_at_hotmail.com)
Date: 12/20/04
- Next message: Steve Edwards: "Re: Multi Table Query Help"
- Previous message: lig: "Re: Multi Table Query Help"
- Next in thread: Michael Fesser: "Re: Leech (?) content of mySQL tables"
- Reply: Michael Fesser: "Re: Leech (?) content of mySQL tables"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 20 Dec 2004 08:35:14 -0800
Well, thank you both for your reaction. I looked at Pedro's option,
but i do not wish to work with UPDATE, because that would only slow
down queries. (thanks for the effort anyway..)
So i looked at badr's option, and i'm really interested, but i found
out that somehow my host doesn't support INNODB types.
What my main goal is to be able to sort the animals by name of the
species.
Of course the species is referred to as an ID number. If species are
birds (id 1), fishes (id 2), and ants (id 3),
The ouput has to be: Instead of:
Forest ant (ants) Eagle
Red ant (ants) Forest Ant
Hawk (birds) Hawk
Eagle (birds) Red Ant
Shark (fishes) Shark
Whale (fishes) Whale
So the animals have to be ordered by something that's not in their
own table, and ordering by species id also is impossible because they
are
not entered in alphabeticaly order...
Later on, the website's admin has to be able to turn species AND
animals on and off, so the query should be this in theory:
SELECT species_names, animal_names FROM animals WHERE
species_status=on AND animal_status=on ORDER BY species_name
Where the species_names and species_status are only defined in the
'species'-table.
I hope it's clear, and that i'm not asking to much... (and that it's
not impossible...)
Greetings knoak
- Next message: Steve Edwards: "Re: Multi Table Query Help"
- Previous message: lig: "Re: Multi Table Query Help"
- Next in thread: Michael Fesser: "Re: Leech (?) content of mySQL tables"
- Reply: Michael Fesser: "Re: Leech (?) content of mySQL tables"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|