utils/db_utils.py
def fetch_taxonomy_fields(tax_id):
    """
    Fetches all fields from RfamLive taxonomy table based on
    the tax id provided

    tax_id: A valid tax id

    return: A dictionary with all taxonomy fields
    """

    cnx = RfamDB.connect()
    cursor = cnx.cursor(dictionary=True)

    query = "Select * from taxonomy where ncbi_id=%s"

    cursor.execute(query % tax_id)

    fields = cursor.fetchall()[0]

    return fields

    Fetches all fields from RfamLive taxonomy table based on
    the tax id provided

    tax_id: A valid tax id

    return: A dictionary with all taxonomy fields
    
Fetches all fields from RfamLive taxonomy table based on
the tax id provided

A valid tax id

A dictionary with all taxonomy fields
Fetches all fields from RfamLive taxonomy table based on the tax id provided A valid tax id A dictionary with all taxonomy fields
def fetch_taxonomy_fields(tax_id):
    cnx = RfamDB.connect()
    cursor = cnx.cursor(dictionary=True)
    query = "Select * from taxonomy where ncbi_id=%s"
    cursor.execute(query % tax_id)
    fields = cursor.fetchall()[0]
    return fields
def fetch_taxonomy_fields ( tax_id ) : cnx = RfamDB . connect ( ) cursor = cnx . cursor ( dictionary = True ) query = "Select * from taxonomy where ncbi_id=%s" cursor . execute ( query % tax_id ) fields = cursor . fetchall ( ) [ 0 ] return fields
Fetches all fields from RfamLive taxonomy table based on
the tax id provided
Fetches all fields from RfamLive taxonomy table based on the tax id provided
"""
    Fetches all fields from RfamLive taxonomy table based on
    the tax id provided

    tax_id: A valid tax id

    return: A dictionary with all taxonomy fields
    """
tax_id