Only process each class for joins once.

Before this change, inheriting from two abstract subclasses of `Genome::SoftwareResult` in Genome resulted in:
```
DBD::Pg::st execute failed: ERROR:  table name "software_result" specified more than once
```

With this change the query succeeds.  A test case is attached that previously failed with:
```
DBD::SQLite::db prepare failed: ambiguous column name: PERSON.name
```
The generated query still lists the same columns multiple times in the `SELECT`, which makes me think it would be better eliminate more places where the same class is processed multiple times.  I'm not sure where it's important to keep duplicates in the inheritance list.
```SQL
select PERSON.name, PERSON.person_id, PERSON.subclass, PERSON.name, PERSON.person_id, PERSON.subclass
from PERSON
where PERSON.subclass = ?
order by PERSON.person_id
```