On 05/15/2009 03:41, Dennis Cote wrote:
>
> Your database would be simpler if you simply combined these two tables
> into a single table in the first place. It would eliminate the need to
> combine them for this type of query. The tables already have a type
> field to distinguish the email
Try
select n.name, p.type, p.addr
from p
join name on p.id = n.id
union
select n.name, e.type, e.addr
from e
join name on e.id = n.id
Patty
On Fri, May 15, 2009 at 12:14 AM, Evan Burkitt wrote:
> This isn't a Sqlite question per se, but I know there are some SQL gurus
On 15/05/2009 2:37 PM, Dennis Cote wrote:
> Evan Burkitt wrote:
>> This isn't a Sqlite question per se, but I know there are some SQL gurus
>> here who might have some insight into this problem. I apologize for
>> being off-topic; I can be shameless when I need help. :)>
>>
>> I have three
Evan Burkitt wrote:
> This isn't a Sqlite question per se, but I know there are some SQL gurus
> here who might have some insight into this problem. I apologize for
> being off-topic; I can be shameless when I need help. :)>
>
> I have three tables, N, P and E. N contains the fields id and name.
This isn't a Sqlite question per se, but I know there are some SQL gurus
here who might have some insight into this problem. I apologize for
being off-topic; I can be shameless when I need help. :)>
I have three tables, N, P and E. N contains the fields id and name. The
other two each contain
5 matches
Mail list logo