def process_query(self, query):
    if isinstance(self.alias, util.string_types):
        alias = query._mapper_zero().mapped_table.alias(self.alias)
    else:
        alias = self.alias
    query._from_obj_alias = sql_util.ColumnAdapter(alias)
def process_query(self, query):
    if isinstance(self.alias, util.string_types):
        alias = query._mapper_zero().mapped_table.alias(self.alias)
    else:
        alias = self.alias
    query._from_obj_alias = sql_util.ColumnAdapter(alias)