def get_insert_cmd(step):
    """Returns the command to be used with an insert for the provided step.

    This takes a predefined step to determine which type of insert is being
    performed during the production of the knownet_mappings combined tables.
    Based off of this step, it returns a MySQL command to be used with an
    INSERT INTO statement.

    Args:
        step (str): the step indicating the step during the production of the
            combined knownet_mapping tables

    Returns:
        str: the command to be used with an INSERT INTO statement at this step
    """
    if step == 'gene':
        cmd = ("SELECT DISTINCT xref.dbprimary_acc, xref.display_label, "
               "external_db.db_name, external_db.priority, "
               "external_db.db_display_name, gene.stable_id "
               "FROM xref INNER JOIN external_db "
               "ON xref.external_db_id = external_db.external_db_id "
               "INNER JOIN object_xref "
               "ON xref.xref_id = object_xref.xref_id "
               "INNER JOIN gene "
               "ON object_xref.ensembl_id = gene.gene_id "
               "WHERE object_xref.ensembl_object_type = 'Gene'")
    elif step == 'transcript':
        cmd = ("SELECT DISTINCT xref.dbprimary_acc, xref.display_label, "
               "external_db.db_name, external_db.priority, "
               "external_db.db_display_name, gene.stable_id "
               "FROM xref INNER JOIN external_db "
               "ON xref.external_db_id = external_db.external_db_id "
               "INNER JOIN object_xref "
               "ON xref.xref_id = object_xref.xref_id "
               "INNER JOIN transcript "
               "ON object_xref.ensembl_id = transcript.transcript_id "
               "INNER JOIN gene "
               "ON transcript.gene_id = gene.gene_id "
               "WHERE object_xref.ensembl_object_type = 'Transcript'")
    elif step == 'translation':
        cmd = ("SELECT DISTINCT xref.dbprimary_acc, xref.display_label, "
               "external_db.db_name, external_db.priority, "
               "external_db.db_display_name, gene.stable_id "
               "FROM xref INNER JOIN external_db "
               "ON xref.external_db_id = external_db.external_db_id "
               "INNER JOIN object_xref "
               "ON xref.xref_id = object_xref.xref_id "
               "INNER JOIN translation "
               "ON object_xref.ensembl_id = translation.translation_id "
               "INNER JOIN transcript "
               "ON translation.transcript_id = transcript.transcript_id "
               "INNER JOIN gene "
               "ON transcript.gene_id = gene.gene_id "
               "WHERE object_xref.ensembl_object_type = 'Translation'")
    elif step == 'transcript2stable':
        cmd = ("SELECT DISTINCT transcript.stable_id AS dbprimary_acc, "
               "transcript.stable_id AS display_label, "
               "'ensembl' AS db_name, "
               "1000 AS priority, "
               "'ensembl' AS db_display_name, "
               "gene.stable_id "
               "FROM transcript "
               "INNER JOIN gene "
               "ON transcript.gene_id = gene.gene_id")
    elif step == 'translation2stable':
        cmd = ("SELECT DISTINCT translation.stable_id AS dbprimary_acc, "
               "translation.stable_id AS display_label, "
               "'ensembl' AS db_name, "
               "1000 AS priority, "
               "'ensembl' AS db_display_name, "
               "gene.stable_id "
               "FROM translation "
               "INNER JOIN transcript "
               "ON translation.transcript_id = transcript.transcript_id "
               "INNER JOIN gene "
               "ON transcript.gene_id = gene.gene_id")
    else:
        cmd = ''
    return cmd