Julia, all,
Here is the query I talked about, which looks at both the galaxy
and specobj tables. This will find magnitudes and isophotal radii of
galaxies with measured redshifts. It will also return the redshift.
-- Please read the note above regarding query limits and spatial queries
select top 10 g.objid,g.ra,g.dec,g.g,g.r,g.g-g.r as gminusr, g.isoA_g,
g.isoB_g, s.z as redshift
from Galaxy g, SpecObj s
where
g.objID = s.bestobjID
AND g.g < 18
AND g.r < 18
AND g.isoA_g < -9999
AND g.isoB_g < -9999
A couple things to point out about the query above
1) Note prefixes - g means galaxy view, s means specobj view
2) Very important! - note line where g.objid=s.bestobjid. This means
that we must check that we are looking at the same object in both the
galaxy and specobj views. Otherwise the query will return all objects
in both tables (300,000 x 700,000 objects!)