<commit_before>package repositories;

import java.util.Collection;
import java.util.Date;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import domain.Route;

@Repository
public interface RouteRepository extends JpaRepository<Route, Integer> {
	
	@Query("select r from Route r where r.origin LIKE %?1% AND r.destination LIKE %?2% AND (?3 IS NULL OR (year(r.departureTime) = year(?3) AND month(r.departureTime) = month(?3) AND day(r.departureTime) = day(?3)))"
			+ "AND (?4 IS NULL OR r.departureTime >= ?4) AND (?5 IS NULL OR r.itemEnvelope = ?5 OR r.itemEnvelope LIKE 'both')"
			+ "AND (?6 IS NULL OR (select sp.size from SizePrice sp where sp.route.id = r.id AND sp.size LIKE ?6) IS NOT NULL)")
	Collection<Route> searchRoute(String origin, String destination, Date date, Date time, String envelope, String itemSize);
	
}<commit_msg>Arreglado pequeño bug en la query de las rutas<commit_after>package repositories;

import java.util.Collection;
import java.util.Date;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import domain.Route;

@Repository
public interface RouteRepository extends JpaRepository<Route, Integer> {
	
	@Query("select r from Route r where r.origin LIKE %?1% AND r.destination LIKE %?2% AND (?3 IS NULL OR (year(r.departureTime) = year(?3) AND month(r.departureTime) = month(?3) AND day(r.departureTime) = day(?3)))"
			+ "AND (?4 IS NULL OR r.departureTime >= ?4) AND (?5 IS NULL OR r.itemEnvelope = ?5 OR r.itemEnvelope LIKE 'both')"
			+ "AND (?6 IS NULL OR (select sp.size from SizePrice sp where sp.route.id = r.id AND sp.size = ?6) IS NOT NULL)")
	Collection<Route> searchRoute(String origin, String destination, Date date, Date time, String envelope, String itemSize);
	
}
{'fraction_non_alphanumeric': 0.12076053442959918, 'fraction_numerical': 0.012332990750256937, 'mean_word_length': 5.141955835962145, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6030735', 'n_tokens_mistral': 648, 'n_tokens_neox': 615, 'n_words': 203}