private void loadToDB(String[] fields) {
    if (fields.length >= 4) {
      String accession = fields[0];
      String pathwayId = fields[1];
      String pathwayUrl = fields[2];
      String pathwayName = fields[3];
      String status = fields[4];
      String species = fields[5];

      // check if accession is an enzyme
      UniprotEntry enzyme = uniprotEntryRepository.findByAccession(accession);

      if (enzyme != null) {

        //                EnzymePortalPathways pathways = new EnzymePortalPathways();
        //                pathways.setUniprotAccession(enzyme);
        //                pathways.setPathwayId(pathwayId);
        //                pathways.setPathwayName(pathwayName);
        //                pathways.setPathwayUrl(pathwayUrl);
        //                pathways.setSpecies(species);
        //                pathways.setStatus(status);
        //                pathwaysRepository.saveAndFlush(pathways);
        parserService.createPathway(accession, pathwayId, pathwayUrl, pathwayName, status, species);

        /** Printing the value read from file to the console */
        //        System.out.println(accession + "\t" + pathwayId + "\t" + pathwayUrl + "\t"
        //                + pathwayName + "\t" + status + "\t" + species);
      }
    }
  }
  private void loadToDB(List<String> fields) {

    if (fields.size() == 6) {
      String accession = fields.get(0);
      String pathwayId = fields.get(1);
      String pathwayUrl = fields.get(2);
      String pathwayName = fields.get(3);
      String status = fields.get(4);
      String species = fields.get(5);

      // check if accession is an enzyme
      UniprotEntry enzyme = uniprotEntryRepository.findByAccession(accession);

      if (enzyme != null) {

        parserService.createPathway(accession, pathwayId, pathwayUrl, pathwayName, status, species);

        /** // * Printing the value read from file to the console // */
        //        System.out.println(accession + "\t" + pathwayId + "\t" + pathwayUrl + "\t"
        //                + pathwayName + "\t" + status + "\t" + species);
      }
    }
  }