[Mpuls-commits] r4273 - in jmd/trunk: . jmdweb/public/xml
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Tue Nov 30 11:20:44 CET 2010
Author: torsten
Date: 2010-11-30 11:20:43 +0100 (Tue, 30 Nov 2010)
New Revision: 4273
Modified:
jmd/trunk/ChangeLog
jmd/trunk/jmdweb/public/xml/eval_cm.xml
jmd/trunk/jmdweb/public/xml/eval_zielgruppe.xml
Log:
Issue963: Addeed calculation for "unbekannt/keine Angabe" in various evalutions.
Modified: jmd/trunk/ChangeLog
===================================================================
--- jmd/trunk/ChangeLog 2010-11-26 15:27:14 UTC (rev 4272)
+++ jmd/trunk/ChangeLog 2010-11-30 10:20:43 UTC (rev 4273)
@@ -1,3 +1,9 @@
+2010-11-30 Torsten Irlaender <torsten at intevation.de>
+
+ * jmdweb/public/xml/eval_cm.xml,
+ jmdweb/public/xml/eval_zielgruppe.xml: Issue963: Addeed calculation
+ for "unbekannt/keine Angabe" in various evalutions.
+
2010-11-23 Bernhard Herzog <bh at intevation.de>
* jmdweb/model/struktur.py: Remove unused imports
Modified: jmd/trunk/jmdweb/public/xml/eval_cm.xml
===================================================================
--- jmd/trunk/jmdweb/public/xml/eval_cm.xml 2010-11-26 15:27:14 UTC (rev 4272)
+++ jmd/trunk/jmdweb/public/xml/eval_cm.xml 2010-11-30 10:20:43 UTC (rev 4273)
@@ -35,6 +35,13 @@
<join>anzahl</join>
<where>(kompetenzfeststellung=0)</where>
</ydim>
+ <ydim>
+ <label>unbekannt/keine Angabe</label>
+ <field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
+ <table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
+ <join>anzahl</join>
+ <where>(kompetenzfeststellung not in (0,1))</where>
+ </ydim>
</evaluation>
<evaluation>
@@ -238,7 +245,7 @@
<evaluation>
<id>12</id>
<name>Verbleib der jungen Menschen (Datum)</name>
- <desc>Verbleib der jungen Menschen (Datum)</desc>
+ <desc>Zeitraum nach dem der Verbleib des jungen Menschen festgestellt wurde.</desc>
<basequery>
<table>master_tbl_eval_total_view</table>
<template>SELECT id, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
Modified: jmd/trunk/jmdweb/public/xml/eval_zielgruppe.xml
===================================================================
--- jmd/trunk/jmdweb/public/xml/eval_zielgruppe.xml 2010-11-26 15:27:14 UTC (rev 4272)
+++ jmd/trunk/jmdweb/public/xml/eval_zielgruppe.xml 2010-11-30 10:20:43 UTC (rev 4273)
@@ -19,6 +19,20 @@
<join>geschlecht</join>
</xdim>
<ydim>
+ <label>unbekannt/keine Angabe</label>
+ <field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
+ <table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
+ <join>anzahl</join>
+ <where>(geburtsdatum in (NULL, '0001-01-01'::date))</where>
+ </ydim>
+ <ydim>
+ <label>jünger als 12 Jahre</label>
+ <field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
+ <table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
+ <join>anzahl</join>
+ <where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) < 12)</where>
+ </ydim>
+ <ydim>
<label>12 bis 14 Jahre</label>
<field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
<table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
@@ -41,6 +55,13 @@
<where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) > 18 AND date_part('year', age('%(edate)s'::date, geburtsdatum)) <= 27)</where>
</ydim>
<ydim>
+ <label>älter als 27 Jahre</label>
+ <field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
+ <table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
+ <join>anzahl</join>
+ <where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) > 27)</where>
+ </ydim>
+ <ydim>
<label>Gesamt</label>
<field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
<table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
@@ -49,13 +70,57 @@
</ydim>
</evaluation>
<evaluation>
+ <id>17</id>
+ <name>Migrationshintergrund (Alter unbekannt/keine Angabe)</name>
+ <desc>Definiton und Aufteilung nach Mikrozensus 2005</desc>
+ <basequery>
+ <table>master_tbl_eval_total_view</table>
+ <template>SELECT id, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
+ <where>(geburtsdatum in (NULL, '0001-01-01'::date))</where>
+ </basequery>
+ <xdim>
+ <label>Geschlecht</label>
+ <field>geschlecht</field>
+ <table>geschlecht_tbl</table>
+ <join>geschlecht</join>
+ </xdim>
+ <ydim>
+ <label>Status</label>
+ <field>aufenthaltsstatus</field>
+ <table>aufenthaltsstatus_tbl</table>
+ <join>aufenthaltsstatus</join>
+ </ydim>
+ </evaluation>
+ <evaluation>
+ <id>18</id>
+ <name>Migrationshintergrund (jünger als 12 Jahre)</name>
+ <desc>Definiton und Aufteilung nach Mikrozensus 2005</desc>
+ <basequery>
+ <table>master_tbl_eval_total_view</table>
+ <template>SELECT id, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
+ <where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) < 12)</where>
+ </basequery>
+ <xdim>
+ <label>Geschlecht</label>
+ <field>geschlecht</field>
+ <table>geschlecht_tbl</table>
+ <join>geschlecht</join>
+ </xdim>
+ <ydim>
+ <label>Status</label>
+ <field>aufenthaltsstatus</field>
+ <table>aufenthaltsstatus_tbl</table>
+ <join>aufenthaltsstatus</join>
+ </ydim>
+ </evaluation>
+ <evaluation>
<id>2</id>
<name>Migrationshintergrund (Alter von 12 bis 14 Jahre)</name>
<desc>Definiton und Aufteilung nach Mikrozensus 2005</desc>
<basequery>
<table>master_tbl_eval_total_view</table>
<template>SELECT id, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
- <where>(date_part('year', age(datum_ea_start, geburtsdatum)) >= 12 AND date_part('year', age(datum_ea_start, geburtsdatum)) <= 14)</where>
+ <where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) >= 12 AND date_part('year', age('%(edate)s'::date, geburtsdatum)) <= 14)</where>
</basequery>
<xdim>
<label>Geschlecht</label>
@@ -77,7 +142,7 @@
<basequery>
<table>master_tbl_eval_total_view</table>
<template>SELECT id, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
- <where>(date_part('year', age(datum_ea_start, geburtsdatum)) > 14 AND date_part('year', age(datum_ea_start, geburtsdatum)) <= 18)</where>
+ <where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) > 14 AND date_part('year', age('%(edate)s'::date, geburtsdatum)) <= 18)</where>
</basequery>
<xdim>
<label>Geschlecht</label>
@@ -99,7 +164,7 @@
<basequery>
<table>master_tbl_eval_total_view</table>
<template>SELECT id, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
- <where>(date_part('year', age(datum_ea_start, geburtsdatum)) > 18 AND date_part('year', age(datum_ea_start, geburtsdatum)) <= 27)</where>
+ <where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) > 18 AND date_part('year', age('%(edate)s'::date, geburtsdatum)) <= 27)</where>
</basequery>
<xdim>
<label>Geschlecht</label>
@@ -114,6 +179,28 @@
<join>aufenthaltsstatus</join>
</ydim>
</evaluation>
+ <evaluation>
+ <id>19</id>
+ <name>Migrationshintergrund (älter als 27 Jahre)</name>
+ <desc>Definiton und Aufteilung nach Mikrozensus 2005</desc>
+ <basequery>
+ <table>master_tbl_eval_total_view</table>
+ <template>SELECT id, %(xfield)s, %(yfield)s from %(from)s WHERE %(where)s</template>
+ <where>(date_part('year', age('%(edate)s'::date, geburtsdatum)) > 27)</where>
+ </basequery>
+ <xdim>
+ <label>Geschlecht</label>
+ <field>geschlecht</field>
+ <table>geschlecht_tbl</table>
+ <join>geschlecht</join>
+ </xdim>
+ <ydim>
+ <label>Status</label>
+ <field>aufenthaltsstatus</field>
+ <table>aufenthaltsstatus_tbl</table>
+ <join>aufenthaltsstatus</join>
+ </ydim>
+ </evaluation>
<evaluation>
@@ -132,35 +219,42 @@
<join>geschlecht</join>
</xdim>
<ydim>
+ <label>Einreisedatum unbekannt/keine Angabe</label>
+ <field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
+ <table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
+ <join>anzahl</join>
+ <where>(einreisedatum in (NULL, '0001-01-01'::date))</where>
+ </ydim>
+ <ydim>
<label>Zuzug im letzten Jahr</label>
<field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
<table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
<join>anzahl</join>
- <where>(date_part('year', age(datum_ea_start, einreisedatum)) >= 1
- AND date_part('year', age(datum_ea_start, einreisedatum)) < 3)</where>
+ <where>(date_part('year', age('%(edate)s'::date, einreisedatum)) >= 1
+ AND date_part('year', age('%(edate)s'::date, einreisedatum)) < 3)</where>
</ydim>
<ydim>
<label>Zuzug zwischen 3 und 6 Jahren</label>
<field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
<table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
<join>anzahl</join>
- <where>(date_part('year', age(datum_ea_start, einreisedatum)) >= 3
- AND date_part('year', age(datum_ea_start, einreisedatum)) < 6)</where>
+ <where>(date_part('year', age('%(edate)s'::date, einreisedatum)) >= 3
+ AND date_part('year', age('%(edate)s'::date, einreisedatum)) < 6)</where>
</ydim>
<ydim>
<label>Zuzug zwischen 6 und 10 Jahren</label>
<field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
<table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
<join>anzahl</join>
- <where>(date_part('year', age(datum_ea_start, einreisedatum)) >= 6
- AND date_part('year', age(datum_ea_start, einreisedatum)) < 10)</where>
+ <where>(date_part('year', age('%(edate)s'::date, einreisedatum)) >= 6
+ AND date_part('year', age('%(edate)s'::date, einreisedatum)) < 10)</where>
</ydim>
<ydim>
<label>Zuzug vor mehr als 10 Jahren</label>
<field>(select count(id) from master_tbl_eval_total_view) as anzahl</field>
<table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
<join>anzahl</join>
- <where>(date_part('year', age(datum_ea_start, einreisedatum)) >= 10)</where>
+ <where>(date_part('year', age('%(edate)s'::date, einreisedatum)) >= 10)</where>
</ydim>
<ydim>
<label>Seit der Geburt in Deutschland</label>
@@ -198,8 +292,15 @@
<field>(SELECT COUNT(id) FROM master_tbl_eval_total_view) as anzahl</field>
<table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
<join>anzahl</join>
- <where>(sprache_zuhause NOT IN (3,11,115,14,18,19,23,29,33,71,38,39,52,76,77,80,81,86,91,104,107,111))</where>
+ <where>(sprache_zuhause NOT IN (-1,-3,3,11,115,14,18,19,23,29,33,71,38,39,52,76,77,80,81,86,91,104,107,111))</where>
</ydim>
+ <ydim>
+ <label>unbekannt/keine Angabe</label>
+ <field>(SELECT COUNT(id) FROM master_tbl_eval_total_view) as anzahl</field>
+ <table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
+ <join>anzahl</join>
+ <where>(sprache_zuhause IN (-3,-1))</where>
+ </ydim>
</evaluation>
<evaluation>
@@ -238,6 +339,13 @@
<join>anzahl</join>
<where>(staatsangehoerigkeit = 29 AND staatsangehoerigkeit_weitere NOT IN (-1, -3, 193))</where>
</ydim>
+ <ydim>
+ <label>unbekannt/keine Angabe</label>
+ <field>(SELECT COUNT(id) FROM master_tbl_eval_total_view) as anzahl</field>
+ <table>(select DISTINCT count(id) as id, 'Gesamt' as value from master_tbl_eval_total_view)</table>
+ <join>anzahl</join>
+ <where>(staatsangehoerigkeit in (-1, -3))</where>
+ </ydim>
</evaluation>
<evaluation>
More information about the Mpuls-commits
mailing list