utils/db_utils.py
def fetch_all_upids():
    """
    Fetch all available genome accessions from genome table

    return: A list of UP/RG ids as stored in genome
    """

    # connect to db
    cnx = RfamDB.connect()

    # get a new buffered cursor
    cursor = cnx.cursor(buffered=True)

    # update is_significant field to 0
    query = "select upid from genome"

    cursor.execute(query)

    genome_accs = [str(x[0]) for x in cursor.fetchall()]

    cursor.close()
    RfamDB.disconnect(cnx)

    return genome_accs

    Fetch all available genome accessions from genome table

    return: A list of UP/RG ids as stored in genome
    
Fetch all available genome accessions from genome table
return: A list of UP/RG ids as stored in genome
Fetch all available genome accessions from genome table return : A list of UP / RG ids as stored in genome
def fetch_all_upids():
    cnx = RfamDB.connect()
    cursor = cnx.cursor(buffered=True)
    query = "select upid from genome"
    cursor.execute(query)
    genome_accs = [str(x[0]) for x in cursor.fetchall()]
    cursor.close()
    RfamDB.disconnect(cnx)
    return genome_accs
def fetch_all_upids ( ) : cnx = RfamDB . connect ( ) cursor = cnx . cursor ( buffered = True ) query = "select upid from genome" cursor . execute ( query ) genome_accs = [ str ( x [ 0 ] ) for x in cursor . fetchall ( ) ] cursor . close ( ) RfamDB . disconnect ( cnx ) return genome_accs
Fetch all available genome accessions from genome table
return: A list of UP/RG ids as stored in genome
Fetch all available genome accessions from genome table return : A list of UP / RG ids as stored in genome
"""
    Fetch all available genome accessions from genome table

    return: A list of UP/RG ids as stored in genome
    """ # connect to db # get a new buffered cursor # update is_significant field to 0