Interface VidRepository

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

    public interface VidRepository
    extends org.springframework.data.jpa.repository.JpaRepository<VidEntity,​String>
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      long countByStatusAndIsDeletedFalse​(String status)  
      List<VidEntity> findByStatusAndIsDeletedFalse​(String status)  
      VidEntity findFirstByStatus​(String status)  
      void updateVid​(String status, String contextUser, LocalDateTime uptimes, String vid)  
      • Methods inherited from interface org.springframework.data.repository.CrudRepository

        count, delete, deleteAll, deleteAll, deleteById, existsById, findById, save
      • Methods inherited from interface org.springframework.data.jpa.repository.JpaRepository

        deleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAllById, flush, getOne, saveAll, 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 Detail

      • findFirstByStatus

        @Query(value="select v.vid,v.vid_status,v.expiry_dtimes,v.cr_by, v.cr_dtimes, v.del_dtimes, v.is_deleted, v.upd_by, v.upd_dtimes from kernel.vid v where v.vid_status=? limit 1 FOR UPDATE",
               nativeQuery=true)
        VidEntity findFirstByStatus​(String status)
      • countByStatusAndIsDeletedFalse

        long countByStatusAndIsDeletedFalse​(String status)
      • findByStatusAndIsDeletedFalse

        List<VidEntity> findByStatusAndIsDeletedFalse​(String status)
      • updateVid

        @Modifying
        @Query(value="UPDATE kernel.vid SET vid_status=:status, upd_by=:contextUser, upd_dtimes=:uptimes where vid=:vid",
               nativeQuery=true)
        void updateVid​(@Param("status")
                       String status,
                       @Param("contextUser")
                       String contextUser,
                       @Param("uptimes")
                       LocalDateTime uptimes,
                       @Param("vid")
                       String vid)