Browse Source

Standort aus unikey ermitteln #20

COStage_0.4_Release
Daniel Quathamer 9 months ago
parent
commit
f30d3e180a
  1. 4
      src-modules/module/costage/conf/costage.xml
  2. 16
      src-modules/module/costage/masken/43040_felderinfo.unl
  3. 2
      src-modules/module/costage/masken/43040_maskeninfo.unl
  4. 31
      src-modules/module/costage/rohdaten_sos/sos_costage_unload.xml
  5. 27
      src-modules/module/costage/rohdaten_zul/zul_costage_unload.xml
  6. 1
      src-modules/module/costage/schluesseltabellen/sx_repository.unl
  7. 19
      src-modules/module/costage/schluesseltabellen/trans_costage_st_studiengaenge.sql
  8. 16
      src-modules/module/costage/schluesseltabellen/trans_costage_st_studienkennzahlen.sql

4
src-modules/module/costage/conf/costage.xml

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<module name="costage" version="0.3" sachgebiet_id="310" <module name="costage" version="0.4b" sachgebiet_id="310"
sachgebiet="CO Basisdaten" systeminfo_id="310" sachgebiet="CO Basisdaten" systeminfo_id="310"
system="CO Basisdaten" thema="CO Basisdaten" thema_parent="Studierende, Prüfungen"> system="CO Basisdaten" thema="CO Basisdaten" thema_parent="Studierende, Prüfungen">
<database name="superx" system="superx"> <database name="superx" system="superx">
@ -290,6 +290,8 @@ rightname="CS_BIA_STANDARDREPORTS_ADMIN[CO]" />
<column name="stufrm" type ="CHAR" size ="10" default ="" notnull ="false" description="Studienform"/> <column name="stufrm" type ="CHAR" size ="10" default ="" notnull ="false" description="Studienform"/>
<column name="pversion" type ="VARCHAR" size ="255" default ="" notnull ="false" description="SPO-Version" currentlyUsed="false"/> <column name="pversion" type ="VARCHAR" size ="255" default ="" notnull ="false" description="SPO-Version" currentlyUsed="false"/>
<column name="rsz" type ="INTEGER" size ="255" default ="" notnull ="false" description="Regelstudienzeit"/> <column name="rsz" type ="INTEGER" size ="255" default ="" notnull ="false" description="Regelstudienzeit"/>
<column name="stort_nr" type ="VARCHAR" size ="4" default ="" notnull ="false" description="Standort Nr." />
<column name="stort_name" type ="VARCHAR" size ="255" default ="" notnull ="false" description="Standort Name" />
</columns> </columns>
<indexes></indexes> <indexes></indexes>

16
src-modules/module/costage/masken/43040_felderinfo.unl

@ -52,8 +52,22 @@ order by 2\
43054^Schlüssel anzeigen^150^0^0^100^100^1^integer^30^1^1^<<SQL>> select 1,'Ja' from xdummy union select 0,'Nein' from xdummy^^<<SQL>> select 1,'Ja' from xdummy^ 43054^Schlüssel anzeigen^150^0^0^100^100^1^integer^30^1^1^<<SQL>> select 1,'Ja' from xdummy union select 0,'Nein' from xdummy^^<<SQL>> select 1,'Ja' from xdummy^
43055^tablestylesheet^121^0^0^100^200^1^char^200^1^1^<<SQL>> select distinct filename,X.caption,ord from sx_stylesheets X,sx_mask_style S where X.tid=S.stylesheet_id and S.maskeninfo_id=43040 order by ord^^<<SQL>> select distinct filename,X.caption from sx_stylesheets X,sx_mask_style S where X.tid=S.stylesheet_id and S.maskeninfo_id=43040 and S.ord=1^ 43055^tablestylesheet^121^0^0^100^200^1^char^200^1^1^<<SQL>> select distinct filename,X.caption,ord from sx_stylesheets X,sx_mask_style S where X.tid=S.stylesheet_id and S.maskeninfo_id=43040 order by ord^^<<SQL>> select distinct filename,X.caption from sx_stylesheets X,sx_mask_style S where X.tid=S.stylesheet_id and S.maskeninfo_id=43040 and S.ord=1^
43056^Ausgabeformat^2001^0^0^100^150^1^char^200^1^1^<<SQL>> select element_value,description from menu_element where element='Ausgabeformat' and nature::smallint<100 order by nature::smallint^^<<SQL>> select element_value,description from menu_element where element='Ausgabeformat' and description='HTML'^ 43056^Ausgabeformat^2001^0^0^100^150^1^char^200^1^1^<<SQL>> select element_value,description from menu_element where element='Ausgabeformat' and nature::smallint<100 order by nature::smallint^^<<SQL>> select element_value,description from menu_element where element='Ausgabeformat' and description='HTML'^
43059^Hochschule^5^350^-1^140^80^1^char^255^0^1^<<SQL>>select distinct K.unikey,K.unikey\ 43059^Hochschule / Standort^5^350^-1^140^80^1^char^255^0^1^<<SQL>> --freemarker template \
<#if COSTAGE_STORT?exists && COSTAGE_STORT !="">\
<#assign inlineTemplate=COSTAGE_STORT?interpret />\
<@inlineTemplate/>\
</#if>\
<#if stort?exists>\
<#foreach st in stort>\
select '${st.nr}','${st.name}' from xdummy\
<#if st?has_next>\
union\
</#if>\
</#foreach>\
<#else>\
select distinct K.unikey,K.unikey\
from costage_st_studienkennzahlen K\ from costage_st_studienkennzahlen K\
</#if>\
order by 2;^ ^<<SQL>> select distinct K.unikey,K.unikey\ order by 2;^ ^<<SQL>> select distinct K.unikey,K.unikey\
from costage_st_studienkennzahlen K, hochschulinfo H\ from costage_st_studienkennzahlen K, hochschulinfo H\
where K.unikey=H.hs_nr::char(10)^ where K.unikey=H.hs_nr::char(10)^

2
src-modules/module/costage/masken/43040_maskeninfo.unl

@ -75,7 +75,7 @@ SELECT name,\
/* and fach_nr =<<Fach-Nr.>> */\ /* and fach_nr =<<Fach-Nr.>> */\
/* and costage_st_studien_aggr.st_studstamm_nr in (select S.st_studstamm_nr from costage_st_studierendenstammdaten S where S.st_land1_nr in (<<Staatsangehörigkeit>>) ) */\ /* and costage_st_studien_aggr.st_studstamm_nr in (select S.st_studstamm_nr from costage_st_studierendenstammdaten S where S.st_land1_nr in (<<Staatsangehörigkeit>>) ) */\
/* and costage_st_studien_aggr.st_studstamm_nr in (select S2.st_studstamm_nr from costage_st_studierendenstammdaten S2 where S2.geschlecht = <<Geschlecht>> ) */\ /* and costage_st_studien_aggr.st_studstamm_nr in (select S2.st_studstamm_nr from costage_st_studierendenstammdaten S2 where S2.geschlecht = <<Geschlecht>> ) */\
/* and costage_st_studien_aggr.unikey=<<Hochschule>> */\ /* and costage_st_studien_aggr.unikey=<<Hochschule / Standort>> */\
" />\ " />\
\ \
\ \

31
src-modules/module/costage/rohdaten_sos/sos_costage_unload.xml

@ -196,7 +196,7 @@ F.hssem,
'' ,--stuart, '' ,--stuart,
'' ,--stutyp, '' ,--stutyp,
G.stufrm, G.stufrm,
'' ,--stort, G.stort_nr ,--stort,
F.ruebeudat, F.ruebeudat,
null::char(1) ,--semgewicht, null::char(1) ,--semgewicht,
null::char(1) ,--stggewicht, null::char(1) ,--stggewicht,
@ -224,6 +224,7 @@ and F.kz_rueck_beur_ein is not null
AND F.semester >= $start_stud_sem AND F.semester >= $start_stud_sem
and ($EXTERNAL_SUBJECTS ='true' and ($EXTERNAL_SUBJECTS ='true'
or F.unikey=(select H.hs_nr::char(10) from hochschulinfo H) or F.unikey=(select H.hs_nr::char(10) from hochschulinfo H)
or exists(select id from sx_repository R where R.id='COSTAGE_STORT' and aktiv=1)
) )
; ;
@ -478,7 +479,7 @@ K.skz_name as dtxt,
K.skz_name as ltxt , K.skz_name as ltxt ,
F.statistik_code::char(10) as astat, F.statistik_code::char(10) as astat,
null::char(10) as parent, null::char(10) as parent,
'', --sortc1 K.skz_key, --uniquename
' ', ' ',
' ', --sprache ' ', --sprache
null::date as gueltig_von, null::date as gueltig_von,
@ -493,6 +494,7 @@ null as sortorder
on ( F.st_stdfach_nr=K.st_stdfach_nr) on ( F.st_stdfach_nr=K.st_stdfach_nr)
where ($EXTERNAL_SUBJECTS ='true' where ($EXTERNAL_SUBJECTS ='true'
or unikey=(select H.hs_nr::char(10) from hochschulinfo H) or unikey=(select H.hs_nr::char(10) from hochschulinfo H)
or exists(select id from sx_repository R where R.id='COSTAGE_STORT' and aktiv=1)
) )
union union
@ -795,7 +797,28 @@ null as lid,
null as parent_lid, null as parent_lid,
null as sortorder null as sortorder
FROM xdummy FROM xdummy
union
SELECT distinct
9012,
0,
stort_nr,
stort_nr as ktxt,
stort_name as dtxt,
stort_name as ltxt ,
stort_nr as astat,
' ',
stort_nr,
' ',
' ',
null::date as gueltig_von,
null::date as gueltig_bis,
'5', --sourcesystem_id
' ' , --hiskey_id
' ' , --struktur_c
null as lid,
null as parent_lid,
null as sortorder
FROM costage_st_studiengaenge
; ;
]]> ]]>
@ -865,7 +888,7 @@ SELECT substring(G.studiengangs_identifikator from 1 for 10) ,--abstgv,
string_not_null(G.fachkennzeichen) as kzfa, string_not_null(G.fachkennzeichen) as kzfa,
null::integer,--immsemkz, null::integer,--immsemkz,
null::integer,--kzfaarray, null::integer,--kzfaarray,
null::integer,--stort, G.stort_nr,--stort,
'', -- lehreinh, '', -- lehreinh,
null::integer,--stkkurs1, null::integer,--stkkurs1,
null::integer,--stkkurs2, null::integer,--stkkurs2,

27
src-modules/module/costage/rohdaten_zul/zul_costage_unload.xml

@ -186,7 +186,7 @@ A.fachsemester as stgsem,
null,--stgspz, null,--stgspz,
null,--dowunsch1, null,--dowunsch1,
null,--dowunsch2, null,--dowunsch2,
null, --antr_stort, G.stort_nr, --antr_stort,
null,--haerteantr, null,--haerteantr,
null,--haerte, null,--haerte,
null,--haertegrd, null,--haertegrd,
@ -279,6 +279,7 @@ where A.st_studiengang_nr=G.st_studiengang_nr
and A.bw_typ_kb !='MBW' and A.bw_typ_kb !='MBW'
and ($EXTERNAL_SUBJECTS ='true' and ($EXTERNAL_SUBJECTS ='true'
or A.unikey=(select H.hs_nr::char(10) from hochschulinfo H) or A.unikey=(select H.hs_nr::char(10) from hochschulinfo H)
or exists(select id from sx_repository R where R.id='COSTAGE_STORT' and aktiv=1)
) )
; ;
@ -549,7 +550,29 @@ from costage_st_land_regionen R, costage_st_laender L
where L.st_land_nr=R.st_land_nr where L.st_land_nr=R.st_land_nr
and L.statistik_code='000' and L.statistik_code='000'
and R.statistik_code is not null and R.statistik_code is not null
union
SELECT distinct
9012,
0,
stort_nr,
stort_nr as ktxt,
stort_name as dtxt,
stort_name as ltxt ,
stort_nr as astat,
' ',
stort_nr as uniquename,
null::integer as sortorder,
' ' as bund_apnr,
' ', --sprache
null::date as gueltig_von,
null::date as gueltig_bis,
stort_nr::varchar(255), --sourcesystem_id
null::char(10) , --hiskey_id
null as struktur_c,
null as lid,
null as parent_lid
FROM costage_st_studiengaenge
;
]]> ]]>
</extraction-sql> </extraction-sql>

1
src-modules/module/costage/schluesseltabellen/sx_repository.unl

@ -1 +1,2 @@
1^COSTAGE_STUDENT_FILTER^1=1^Filter Studierende für CO^Hier werden Studierende für Auswertungen aus CO gefiltert^^COSTAGE_STUD_FILTER^^^310^1^0^0^^1^01.01.1900^31.12.3000^ 1^COSTAGE_STUDENT_FILTER^1=1^Filter Studierende für CO^Hier werden Studierende für Auswertungen aus CO gefiltert^^COSTAGE_STUD_FILTER^^^310^1^0^0^^1^01.01.1900^31.12.3000^
2^COSTAGE_STORT^^Standorte^Hier werden Standorte konfiguriert^^COSTAGE_STORT^^^310^1^0^0^^0^01.01.1900^31.12.3000^

19
src-modules/module/costage/schluesseltabellen/trans_costage_st_studiengaenge.sql

@ -1,3 +1,10 @@
--freemarker template
<#if COSTAGE_STORT?exists && COSTAGE_STORT !="">
<#assign inlineTemplate=COSTAGE_STORT?interpret />
<@inlineTemplate/>
</#if>
delete from costage_st_studiengaenge; delete from costage_st_studiengaenge;
@ -33,6 +40,9 @@ st_studiengang_nr,
--transformiere Fach/Abschluss etc. nach SuperX Notation --transformiere Fach/Abschluss etc. nach SuperX Notation
--Fach: --Fach:
update costage_st_studiengaenge set skz_key=SKZ.skz_key update costage_st_studiengaenge set skz_key=SKZ.skz_key
<#if stort?exists>
,stort_nr=SKZ.unikey
</#if>
from costage_st_studienkennzahlen SKZ from costage_st_studienkennzahlen SKZ
where SKZ.st_skz_nr=costage_st_studiengaenge.st_skz_nr; where SKZ.st_skz_nr=costage_st_studiengaenge.st_skz_nr;
--Abschluss: --Abschluss:
@ -48,3 +58,12 @@ where S.st_studium_nr = P.st_studium_nr
and S.st_studiengang_nr=costage_st_studiengaenge.st_studiengang_nr and S.st_studiengang_nr=costage_st_studiengaenge.st_studiengang_nr
and P.stp_stp_nr=costage_st_studiengaenge.stp_stp_nr; and P.stp_stp_nr=costage_st_studiengaenge.stp_stp_nr;
--Standorte name:
<#if stort?exists>
<#foreach st in stort>
update costage_st_studiengaenge set stort_name='${st.name}'
where stort_nr='${st.nr}';
</#foreach>
</#if>

16
src-modules/module/costage/schluesseltabellen/trans_costage_st_studienkennzahlen.sql

@ -1,3 +1,8 @@
--freemarker template
<#if COSTAGE_STORT?exists && COSTAGE_STORT !="">
<#assign inlineTemplate=COSTAGE_STORT?interpret />
<@inlineTemplate/>
</#if>
delete from costage_st_studienkennzahlen; delete from costage_st_studienkennzahlen;
@ -20,7 +25,16 @@ S.st_stdfach_nr,
S.gesetzliche_grundlage_kb S.gesetzliche_grundlage_kb
FROM costage_st_studienkennzahlen_neu S, hochschulinfo H FROM costage_st_studienkennzahlen_neu S, hochschulinfo H
where H.hs_nr::char(10)=S.unikey or S.unikey is null where H.hs_nr::char(10)=S.unikey or S.unikey is null
or 1=0
<#if stort?exists>
<#foreach st in stort>
or S.unikey ='${st.nr}'
</#foreach>
</#if>
; ;
<#if stort?exists == false>
--wg. Eindeutigkeit kombinierter Schlüssel SKZ+UNIKEY: --wg. Eindeutigkeit kombinierter Schlüssel SKZ+UNIKEY:
insert into costage_st_studienkennzahlen( insert into costage_st_studienkennzahlen(
st_skz_nr, st_skz_nr,
@ -42,5 +56,5 @@ S.gesetzliche_grundlage_kb
FROM costage_st_studienkennzahlen_neu S, hochschulinfo H FROM costage_st_studienkennzahlen_neu S, hochschulinfo H
where H.hs_nr::char(10)!=S.unikey where H.hs_nr::char(10)!=S.unikey
; ;
</#if>
--TODO: Duplikatssuche bei Fächern ("skz_key"). --TODO: Duplikatssuche bei Fächern ("skz_key").

Loading…
Cancel
Save