All queries




Query Person.count

SQL query HQL query
select count(distinct person0_.id) as col_0_0_ from PUBLIC.person person0_ inner join PUBLIC.status status1_ on person0_.status_fk=status1_.id left outer join PUBLIC.person2user_profile userprofil2_ on person0_.id=userprofil2_.person_fk left outer join PUBLIC.user_profile userprofil3_ on userprofil2_.user_profile_fk=userprofil3_.id where ( :userProfileId is null or userprofil3_.id=:userProfileId ) and ( :statusIds is null or status1_.id in ( :statusIds ) ) and ( :email is null or upper(person0_.email)=upper(:email) ) and ( :pubkey is null or person0_.pubkey=:pubkey ) and ( :firstName is null or upper(person0_.first_name)=upper(:firstName) ) and ( :lastName is null or upper(person0_.last_name)=upper(:lastName) ); SELECT count(distinct t.id) FROM Person t inner join t.status s left outer join t.userProfiles up WHERE (:userProfileId is null OR up.id = :userProfileId) AND (:statusIds is null OR s.id IN (:statusIds)) AND (:email is null OR upper(t.email) = upper(:email)) AND (:pubkey is null OR t.pubkey = :pubkey) AND (:firstName is null OR upper(t.firstName) = upper(:firstName)) AND (:lastName is null OR upper(t.lastName) = upper(:lastName))



Query RoundWeightConversion.dressingByTaxonGroupId

SQL query HQL query
select distinct qualitativ1_.id as id1_63_, qualitativ1_.comments as comments2_63_, qualitativ1_.creation_date as creation3_63_, qualitativ1_.description as descript4_63_, qualitativ1_.label as label5_63_, qualitativ1_.name as name6_63_, qualitativ1_.parameter_fk as paramete8_63_, qualitativ1_.status_fk as status_f9_63_, qualitativ1_.update_date as update_d7_63_ from PUBLIC.round_weight_conversion roundweigh0_ inner join PUBLIC.qualitative_value qualitativ1_ on roundweigh0_.dressing_fk=qualitativ1_.id where ( roundweigh0_.taxon_group_fk in ( select taxongroup2_.parent_taxon_group_fk from PUBLIC.taxon_group_hierarchy taxongroup2_ where taxongroup2_.child_taxon_group_fk=:taxonGroupId ) ) and roundweigh0_.location_fk=:locationId and qualitativ1_.status_fk<>0 and roundweigh0_.start_date<=:endDate and coalesce(roundweigh0_.end_date, :startDate)>=:startDate; SELECT DISTINCT c.dressing FROM RoundWeightConversion c WHERE c.taxonGroup.id IN ( SELECT tgh.id.parentTaxonGroup.id FROM TaxonGroupHierarchy tgh WHERE tgh.id.childTaxonGroup.id = :taxonGroupId) AND c.location.id = :locationId AND c.dressing.status.id != 0 AND NOT( c.startDate > :endDate OR coalesce(c.endDate, :startDate) < :startDate )



Query RoundWeightConversion.preservingByTaxonGroupId

SQL query HQL query
select distinct qualitativ1_.id as id1_63_, qualitativ1_.comments as comments2_63_, qualitativ1_.creation_date as creation3_63_, qualitativ1_.description as descript4_63_, qualitativ1_.label as label5_63_, qualitativ1_.name as name6_63_, qualitativ1_.parameter_fk as paramete8_63_, qualitativ1_.status_fk as status_f9_63_, qualitativ1_.update_date as update_d7_63_ from PUBLIC.round_weight_conversion roundweigh0_ inner join PUBLIC.qualitative_value qualitativ1_ on roundweigh0_.preserving_fk=qualitativ1_.id where ( roundweigh0_.taxon_group_fk in ( select taxongroup2_.parent_taxon_group_fk from PUBLIC.taxon_group_hierarchy taxongroup2_ where taxongroup2_.child_taxon_group_fk=:taxonGroupId ) ) and roundweigh0_.location_fk=:locationId and qualitativ1_.status_fk<>0 and roundweigh0_.start_date<=:endDate and coalesce(roundweigh0_.end_date, :startDate)>=:startDate; SELECT DISTINCT c.preserving FROM RoundWeightConversion c WHERE c.taxonGroup.id IN ( SELECT tgh.id.parentTaxonGroup.id FROM TaxonGroupHierarchy tgh WHERE tgh.id.childTaxonGroup.id = :taxonGroupId) AND c.location.id = :locationId AND c.preserving.status.id != 0 AND NOT( c.startDate > :endDate OR coalesce(c.endDate, :startDate) < :startDate )



Query SystemVersion.last

SQL query HQL query
select systemvers0_.label as col_0_0_ from PUBLIC.system_version systemvers0_ where systemvers0_.id=( select max(systemvers1_.id) from PUBLIC.system_version systemvers1_ ); SELECT label as schemaVersion FROM SystemVersion WHERE id = (select max(id) from SystemVersion)