2011/1/28 Nicolas Ribot <nicolas.ribot at gmail.com>: > UPDATE permit_sites SET huc = giddy.gid FROM (SELECT h.gid FROM huc8 h, > permit_sites p WHERE ST_Within(p.the_geom,h.the_geom)) AS giddy; Let me ask a rhetorical question: Which row from the inner SELECT gets connected to which row of the table being updated?