Skip to content

Commit 8c30b1a

Browse files
authored
[7129] resolve date type in query for postgres (#7132)
1 parent 6e4b36a commit 8c30b1a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/data/IBatch2JobInstanceRepository.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,8 @@ List<Batch2JobInstanceEntity> findInstancesByJobIdAndParams(
7373
+ "WHERE (:definitionId IS NULL OR b.myDefinitionId = :definitionId) "
7474
+ "AND (:status IS NULL OR b.myStatus = :status) "
7575
+ "AND (:jobId IS NULL OR b.myId = :jobId) "
76-
+ "AND (:from IS NULL OR b.myCreateTime >= :from) "
77-
+ "AND (:to IS NULL OR b.myCreateTime <= :to)")
76+
+ "AND (cast(:from as date) IS NULL OR b.myCreateTime >= :from) "
77+
+ "AND (cast(:to as date) IS NULL OR b.myCreateTime <= :to)")
7878
Page<Batch2JobInstanceEntity> findByJobDefinitionIdOrStatusOrIdOrCreateTime(
7979
@Param("definitionId") String theDefinitionId,
8080
@Param("status") StatusEnum theStatus,

0 commit comments

Comments
 (0)