This is an automated email from the git hooks/post-receive script. New commit to branch feature/7146 in repository observe. See http://git.codelutin.com/observe.git commit a6be8bf0dd6e83e232732fcea2ebe950ac85c95b Author: Sylvain Bavencoff <bavencoff@codelutin.com> Date: Wed May 27 11:49:49 2015 +0200 refs #7146 : Rejets thons selon le type d'association (439.503 ms ==> 227.16 ms) --- .../src/main/filters/observe-reports.properties | 519 +++++---------------- 1 file changed, 112 insertions(+), 407 deletions(-) diff --git a/observe-business/src/main/filters/observe-reports.properties b/observe-business/src/main/filters/observe-reports.properties index 638a396..342169b 100644 --- a/observe-business/src/main/filters/observe-reports.properties +++ b/observe-business/src/main/filters/observe-reports.properties @@ -439,426 +439,131 @@ report.targetDiscardedByAssociation.operations.2=SumColumn # ligne 1 report.targetDiscardedByAssociation.request.1=0,0|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and ( (so is null and size(a.observedSystem) = 0) or (so.code != 11 and so in elements(a.observedSystem)) ) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'YFT' - -report.targetDiscardedByAssociation.request.2=1,0|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and ( (so is null and size(a.observedSystem) = 0) or (so.code != 11 and so in elements(a.observedSystem)) ) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'SKJ' - -report.targetDiscardedByAssociation.request.3=2,0|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and ( (so is null and size(a.observedSystem) = 0) or (so.code != 11 and so in elements(a.observedSystem)) ) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'BET' - -report.targetDiscardedByAssociation.request.4=3,0|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and ( (so is null and size(a.observedSystem) = 0) or (so.code != 11 and so in elements(a.observedSystem)) ) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'LTA' - -report.targetDiscardedByAssociation.request.5=4,0|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and ( (so is null and size(a.observedSystem) = 0) or (so.code != 11 and so in elements(a.observedSystem)) ) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'FRI' - -report.targetDiscardedByAssociation.request.6=5,0|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ + Select \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then 0.0 \ + Else ct.catchWeight End) \ + From TripSeineImpl m \ + Join m.route r \ + Join r.activitySeine a \ + Join a.setSeine c \ + with c.schoolType = 2 \ + Join c.targetCatch ct \ + with ct.discarded = true, \ + ObservedSystemImpl os \ Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and ( (so is null and size(a.observedSystem) = 0) or (so.code != 11 and so in elements(a.observedSystem)) ) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode NOT IN ( 'YFT', 'SKJ', 'BET', 'LTA', 'FRI' ) + m.id = :tripId \ + and os.topiaId = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9395222812356602' \ + and os not in elements(a.observedSystem) # ligne 2 report.targetDiscardedByAssociation.request.7=0,1|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and so in elements(a.observedSystem) and so.code = 11 \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'YFT' - -report.targetDiscardedByAssociation.request.8=1,1|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and so in elements(a.observedSystem) and so.code = 11 \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'SKJ' - -report.targetDiscardedByAssociation.request.9=2,1|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and so in elements(a.observedSystem) and so.code = 11 \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'BET' - -report.targetDiscardedByAssociation.request.10=3,1|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and so in elements(a.observedSystem) and so.code = 11 \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'LTA' - -report.targetDiscardedByAssociation.request.11=4,1|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and so in elements(a.observedSystem) and so.code = 11 \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'FRI' - -report.targetDiscardedByAssociation.request.12=5,1|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ + Select \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then 0.0 \ + Else ct.catchWeight End) \ + From TripSeineImpl m \ + Join m.route r \ + Join r.activitySeine a \ + Join a.setSeine c \ + with c.schoolType = 2 \ + Join c.targetCatch ct \ + with ct.discarded = true, \ + ObservedSystemImpl os \ Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - left join a.observedSystem as so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 2 \ - and so in elements(a.observedSystem) and so.code = 11 \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode NOT IN ( 'YFT', 'SKJ', 'BET', 'LTA', 'FRI' ) + m.id = :tripId \ + and os.topiaId = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9395222812356602' \ + and os in elements(a.observedSystem) # ligne 3 report.targetDiscardedByAssociation.request.13=0,2|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'YFT' - -report.targetDiscardedByAssociation.request.14=1,2|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'SKJ' - -report.targetDiscardedByAssociation.request.15=2,2|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'BET' - -report.targetDiscardedByAssociation.request.16=3,2|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'LTA' - -report.targetDiscardedByAssociation.request.17=4,2|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'FRI' - -report.targetDiscardedByAssociation.request.18=5,2|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ + Select \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then 0.0 \ + Else ct.catchWeight End) \ + From TripSeineImpl m \ + Join m.route r \ + Join r.activitySeine a \ + Join a.setSeine c \ + with c.schoolType = 1 \ + Join c.targetCatch ct \ + with ct.discarded = true, \ + ObservedSystemImpl os \ Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode NOT IN ( 'YFT', 'SKJ', 'BET', 'LTA', 'FRI' ) + m.id = :tripId \ + and os.topiaId = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' \ + and os in elements(a.observedSystem) # ligne 4 report.targetDiscardedByAssociation.request.19=0,3|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so not in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'YFT' - -report.targetDiscardedByAssociation.request.20=1,3|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so not in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'SKJ' - -report.targetDiscardedByAssociation.request.21=2,3|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so not in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'BET' - -report.targetDiscardedByAssociation.request.22=3,3|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so not in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'LTA' - -report.targetDiscardedByAssociation.request.23=4,3|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ - Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so not in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode = 'FRI' - -report.targetDiscardedByAssociation.request.24=5,3|row|\ - Select Sum(ct.catchWeight) \ - From SetSeineImpl c, TargetCatchImpl ct \ + Select \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then ct.catchWeight \ + Else 0.0 End), \ + Sum(CASE ct.weightCategory.species.topiaId When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.8943253454598569' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685474#0.975344121171992' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685475#0.13349466123905152' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.8024257002747615' Then 0.0 \ + When 'fr.ird.observe.entities.referentiel.Species#1239832685477#0.3846921632590058' Then 0.0 \ + Else ct.catchWeight End) \ + From TripSeineImpl m \ + Join m.route r \ + Join r.activitySeine a \ + Join a.setSeine c \ + with c.schoolType = 1 \ + Join c.targetCatch ct \ + with ct.discarded = true, \ + ObservedSystemImpl os \ Where \ - c in ( \ - Select distinct a.setSeine From TripSeineImpl m, RouteImpl r, ActivitySeineImpl a, ObservedSystemImpl so \ - Where \ - m.id = :tripId \ - and r in elements(m.route) \ - and a in elements(r.activitySeine) \ - and a.setSeine is not null \ - and a.setSeine.reasonForNullSet is null \ - and a.setSeine.schoolType = 1 \ - and so.id = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' and so not in elements(a.observedSystem) \ - ) \ - and ct in elements(c.targetCatch) and ct.discarded = true and ct.weightCategory.species.faoCode NOT IN ( 'YFT', 'SKJ', 'BET', 'LTA', 'FRI' ) + m.id = :tripId \ + and os.topiaId = 'fr.ird.observe.entities.referentiel.seine.ObservedSystem#1239832686428#0.9217864901728908' \ + and os not in elements(a.observedSystem) ################################################################################ ## Captures accessoires observ\u00e9es -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@list.forge.codelutin.com>.