(Die Seite wurde neu angelegt: „<pre> insert into superx_sos(id, mtknr_ldsg,person_id,person_birthdate,person_birthcity,person_k_gender_id) SELECT DISTINCT S.id, S.registrationnumber, S.pers…“) |
Keine Bearbeitungszusammenfassung |
||
Zeile 1: | Zeile 1: | ||
<pre> | <pre>insert into superx_sos(id, mtknr_ldsg,person_id,person_birthdate,person_birthcity,person_k_gender_id) | ||
insert into superx_sos(id, mtknr_ldsg,person_id,person_birthdate,person_birthcity,person_k_gender_id) | |||
SELECT DISTINCT S.id, | SELECT DISTINCT S.id, | ||
S.registrationnumber, | S.registrationnumber, | ||
Zeile 23: | Zeile 22: | ||
--Gasthörer 8 | --Gasthörer 8 | ||
</pre> | </pre> | ||
Wir wollen vorläufige Studierende und Gasthöher mitladen, daher verweiterung auf die IDs 6,8 |
Version vom 20. September 2018, 12:36 Uhr
insert into superx_sos(id, mtknr_ldsg,person_id,person_birthdate,person_birthcity,person_k_gender_id) SELECT DISTINCT S.id, S.registrationnumber, S.person_id, P.birthdate , substring(P.birthcity from 1 for 255), P.k_gender_id from student S, person P where P.id=S.person_id and S.registrationnumber is not null ${STUDENT_FILTER} and '${SOS_UNL_ANON}' != 'true' and ((S.updated_at > '${stu_updated_at}') OR (S.updated_at IS NULL AND '${stu_updated_at}' = '1900-01-01')) --keine vorläufigen Studierenden #118453 --nur Rolle "Student" (hiskey_id=5) and 0<(select count(*) from orgrole O, role R where R.id=O.role_id and S.person_id=O.person_id and R.hiskey_id in (5,6,8)); -- APF 09.05.2018 inc. vorl. Studierende --Promovierende 81 --Gasthörer 8
Wir wollen vorläufige Studierende und Gasthöher mitladen, daher verweiterung auf die IDs 6,8