'Get a list of the record IDs of all import items for
the the given upload ID
@param upload_id: the upload ID
@param as_string: represent each ID as string'

def _get_all_items(self, upload_id, as_string=False):

    item_table = S3ImportJob.define_item_table()
    upload_table = self.upload_table
    query = (((upload_table.id == upload_id) & (item_table.job_id == upload_table.job_id)) & (item_table.tablename == self.controller_tablename))
    rows = current.db(query).select(item_table.id)
    if as_string:
        items = [str(row.id) for row in rows]
    else:
        items = [row.id for row in rows]
    return items
