[Mpuls-commits] r640 - wasko/branches/1.0/waskaweb/public/xml

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Fri Oct 16 11:32:18 CEST 2009


Author: torsten
Date: 2009-10-16 11:32:18 +0200 (Fri, 16 Oct 2009)
New Revision: 640

Modified:
   wasko/branches/1.0/waskaweb/public/xml/eval_tagebuch.xml
Log:
Issue537


Modified: wasko/branches/1.0/waskaweb/public/xml/eval_tagebuch.xml
===================================================================
--- wasko/branches/1.0/waskaweb/public/xml/eval_tagebuch.xml	2009-10-16 07:45:47 UTC (rev 639)
+++ wasko/branches/1.0/waskaweb/public/xml/eval_tagebuch.xml	2009-10-16 09:32:18 UTC (rev 640)
@@ -16,7 +16,7 @@
       <phase>2</phase>
     </requirement>
     <basequery>
-      <table>(select p.id, p.geschlecht, l.art, l.dauer from ka_logbuch_tbl_view l join master_tbl_eval_total_view p on l.master_id = p.id) zzz</table>
+      <table>(select p.id, p.geschlecht, p.nat_muspra, p.nat_staat, p.vater_land, p.mutter_land, l.art, l.dauer from ka_logbuch_tbl_view l join master_tbl_eval_total_view p on l.master_id = p.id) zzz</table>
       <template>SELECT id, EXTRACT(epoch FROM dauer) as dauer, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
       <where>TRUE</where>
       <aggregate>sum(m.dauer)/60</aggregate>
@@ -27,6 +27,20 @@
       <table>geschlecht_tbl</table>
       <join>geschlecht</join>
     </xdim>
+    <xdim>
+      <label>Migration nach Geschlecht</label>
+      <field>(CASE WHEN ((nat_muspra not in (18,-1, -3) or
+      nat_staat not in (1,-1,-3) or vater_land not in (29, -1, -3) or
+      mutter_land not in (29,-1, -3)) and geschlecht = 0) THEN 0 WHEN ((nat_muspra not in (18,-1, -3) or
+      nat_staat not in (1,-1,-3) or vater_land not in (29, -1, -3) or
+      mutter_land not in (29,-1, -3)) and geschlecht = 1) THEN 1 WHEN ((nat_muspra not in (18,-1, -3) or
+      nat_staat not in (1,-1,-3) or vater_land not in (29, -1, -3) or
+      mutter_land not in (29,-1, -3)) and geschlecht = -3) THEN -3 WHEN ((nat_muspra not in (18,-1, -3) or
+      nat_staat not in (1,-1,-3) or vater_land not in (29, -1, -3) or
+      mutter_land not in (29,-1, -3)) and geschlecht = -1) THEN -1 ELSE 10 END) as migration</field>
+      <table>geschlecht_tbl</table>
+      <join>migration</join>
+    </xdim>
     <ydim>
       <label>Unmittelbare Arbeit mit dem Jugendlichen</label>
       <field>art</field>



More information about the Mpuls-commits mailing list