Преглед на файлове

修改统计数据SQL语句

DESKTOP-G6NQ3SI\dante преди 7 години
родител
ревизия
56b4020453
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/repository/patient/PatientDao.java

+ 1 - 1
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/repository/patient/PatientDao.java

@ -65,6 +65,6 @@ public interface PatientDao extends PagingAndSortingRepository<Patient, Long> {
    @Query("select distinct p.openid from Patient p where p.openid is not null and p.openid <> '' ")
    List<String> findOpenids();
    @Query(value=" select distinct p.* from wlyy_patient p INNER JOIN wlyy_sign_family s on s.patient = p.code WHERE s.status > 0  and p.disease >0 and p.status>0 and s.admin_team_code = ?1",nativeQuery = true)
    @Query(value=" select p.* from wlyy_patient p LEFT JOIN wlyy_sign_family s on s.patient = p.code WHERE s.status > 0  and p.disease >0 and p.status>0 and s.admin_team_code = ?1",nativeQuery = true)
    List<Patient> findAllSignPatientTeamcode(String teamcode);
}