public static int addCosmic(CosmicMutationFrequency cosmic) throws DaoException {
    if (!MySQLbulkLoader.isBulkLoad()) {
      throw new DaoException("You have to turn on MySQLbulkLoader in order to insert mutations");
    } else {

      // use this code if bulk loading
      // write to the temp file maintained by the MySQLbulkLoader
      MySQLbulkLoader.getMySQLbulkLoader("cosmic_mutation")
          .insertRecord(
              cosmic.getId(),
              cosmic.getChr(),
              Long.toString(cosmic.getStartPosition()),
              cosmic.getReferenceAllele(),
              cosmic.getTumorSeqAllele(),
              cosmic.getStrand(),
              cosmic.getCds(),
              Long.toString(cosmic.getEntrezGeneId()),
              cosmic.getAminoAcidChange(),
              Integer.toString(cosmic.getFrequency()),
              cosmic.getKeyword());

      return 1;
    }
  }