Re: [sqlite] get records for foreign keys which come from various places

2012-12-02 Thread Igor Tandetnik
e-mail mgbg25171 wrote: > I've only just discovered that you can get rows for foreign keys doing this > > SELECT f.* >FROM firms f >inner JOIN calls c >ON f.id = c.firm_id group by c.firm_id; I don't quite understand

[sqlite] get records for foreign keys which come from various places

2012-12-02 Thread e-mail mgbg25171
I've only just discovered that you can get rows for foreign keys doing this SELECT f.* FROM firms f inner JOIN calls c ON f.id = c.firm_id group by c.firm_id; that's fine where the foreign keys are from a single field in a single table (i.e. firm_id in calls) but what