Interface OrganizationRepository

All Superinterfaces:
org.springframework.data.repository.CrudRepository<Organization,String>, org.springframework.data.jpa.repository.JpaRepository<Organization,String>, org.springframework.data.repository.PagingAndSortingRepository<Organization,String>, org.springframework.data.repository.query.QueryByExampleExecutor<Organization>, org.springframework.data.repository.Repository<Organization,String>

public interface OrganizationRepository extends org.springframework.data.jpa.repository.JpaRepository<Organization,String>
  • Method Summary

    Modifier and Type
    Method
    Description
    long
     
    long
     
    void
     
    void
     
    void
     
    void
    updateStatus(String id, String status)
     

    Methods inherited from interface org.springframework.data.repository.CrudRepository

    count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, save

    Methods inherited from interface org.springframework.data.jpa.repository.JpaRepository

    deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAllById, flush, getById, getOne, saveAll, saveAllAndFlush, saveAndFlush

    Methods inherited from interface org.springframework.data.repository.PagingAndSortingRepository

    findAll

    Methods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor

    count, exists, findAll, findOne
  • Method Details

    • updateCreationDate

      @Modifying @Query("update Organization set created_by = ?2, creation_date = ?3 where id = ?1") void updateCreationDate(String id, String user, OffsetDateTime now)
    • updateModificationDate

      @Modifying @Query("update Organization set modified_by = ?2, modification_date = ?3 where id = ?1") void updateModificationDate(String id, String user, OffsetDateTime now)
    • updateStatus

      @Modifying @Query("update Organization set status = ?2 where id = ?1") void updateStatus(String id, String status)
    • prepareOrgWithId

      @Modifying @Query(value="insert into organizations(id) values (?1)", nativeQuery=true) void prepareOrgWithId(String id)
    • countByStatus

      long countByStatus(String status)
    • countByStatusAndCountry

      long countByStatusAndCountry(String status, String country)