'Create the SQL for this query. Return the SQL string and list of
parameters.'

def as_sql(self):

    (sql, params) = ([], [])
    for annotation in self.query.annotation_select.values():
        (ann_sql, ann_params) = self.compile(annotation, select_format=FORCE)
        sql.append(ann_sql)
        params.extend(ann_params)
    self.col_count = len(self.query.annotation_select)
    sql = ',    '.join(sql)
    params = tuple(params)
    sql = ('SELECT    %s    FROM    (%s)    subquery' % (sql, self.query.subquery))
    params = (params + self.query.sub_params)
    return (sql, params)
