diff --git a/HIRS_AttestationCA/src/main/java/hirs/attestationca/persist/entity/manager/CertificateRepository.java b/HIRS_AttestationCA/src/main/java/hirs/attestationca/persist/entity/manager/CertificateRepository.java index 90f94c1ed..900a30a64 100644 --- a/HIRS_AttestationCA/src/main/java/hirs/attestationca/persist/entity/manager/CertificateRepository.java +++ b/HIRS_AttestationCA/src/main/java/hirs/attestationca/persist/entity/manager/CertificateRepository.java @@ -17,10 +17,10 @@ public interface CertificateRepository extends JpaRepository @Query(value = "SELECT * FROM Certificate where id = ?1", nativeQuery = true) Certificate getCertificate(UUID uuid); - @Query(value = "SELECT * FROM Certificate where issuer = ?1 AND DTYPE = ?2", nativeQuery = true) - List findBySubject(String issuer, String dType); - @Query(value = "SELECT * FROM Certificate where issuerSorted = ?1 AND DTYPE = ?2", nativeQuery = true) - List findBySubjectSorted(String issuedSort, String dType); + @Query(value = "SELECT * FROM Certificate where subject = ?1 AND DTYPE = ?2", nativeQuery = true) + List findBySubject(String subject, String dType); + @Query(value = "SELECT * FROM Certificate where subjectSorted = ?1 AND DTYPE = ?2", nativeQuery = true) + List findBySubjectSorted(String subjectSorted, String dType); @Query(value = "SELECT * FROM Certificate where DTYPE = ?1", nativeQuery = true) List findByType(String dType); @Query(value = "SELECT * FROM Certificate where serialNumber = ?1 AND DTYPE = ?2", nativeQuery = true)