Also I think `sql_as` should take the subquery and it's name. `sql_subquery()` might be a better name.