I am trying to make an anti-plagiarism check on Java in my method in this way.
if (split.trim().toLowerCase().equalsIgnoreCase(antis.trim().toLowerCase())) { anti.append(antis).append(" "); } where the split variable is a long text from the client and the antis variable is from the base the whole problem is that when I launch my query in the facade, antis is always the last entry
code from the front
public String getText() throws Exception{ Query query = null; String answ = null; query = em.createQuery("Select m.text from MyBd m "); List<String> strings = query.getResultList(); for (String answer: strings) { answ = answer; } return answ; }