From d056116ddec4c9d06668193d6ac47c4f99edc514 Mon Sep 17 00:00:00 2001 From: Rudolf Hangl Date: Wed, 16 May 2007 12:21:40 +0000 Subject: [PATCH] --- admin/fas/check_fas_diplomarbeit.php | 331 +++++++++++++++++++++++++++ 1 file changed, 331 insertions(+) create mode 100644 admin/fas/check_fas_diplomarbeit.php diff --git a/admin/fas/check_fas_diplomarbeit.php b/admin/fas/check_fas_diplomarbeit.php new file mode 100644 index 000000000..84b82f07c --- /dev/null +++ b/admin/fas/check_fas_diplomarbeit.php @@ -0,0 +1,331 @@ +, + * Andreas Oesterreicher and + * Rudolf Hangl . + */ + +include('../../vilesci/config.inc.php'); + +$conn=pg_connect(CONN_STRING) or die("Connection zur Portal Datenbank fehlgeschlagen"); +$conn_fas=pg_connect(CONN_STRING_FAS) or die("Connection zur FAS Datenbank fehlgeschlagen"); + +$adress='ruhan@technikum-wien.at'; +//$adress='fas_sync@technikum-wien.at'; + +$error_log=''; +$text = ''; +$anzahl_quelle=0; +$anzahl_eingefuegt=0; +$anzahl_fehler=0; +$i=0; +$k=0; +$qry1=''; +$combobox[]=""; +$valuebox[]=""; +$nachname[]=""; +$zweitbetreuer=''; + +?> + + + +Diplomarbeiten-Datenkorrektur + + + + + +titelpre).' '.trim($rowvilesci->vorname).' '.trim($rowvilesci->nachname)." ".trim($rowvilesci->titelpost)); + $nachname[$i]=trim($rowvilesci->nachname); + $valuebox[$i]=$rowvilesci->person_id; + $i++; + } +} +echo ""; + +$qry="SELECT * FROM diplomarbeit + WHERE + ((vilesci_zweitbegutachter IS NULL AND trim(zweitbegutachter)!='') OR + (vilesci_betreuer IS NULL AND trim(betreuer)!='') OR + (vilesci_firmenbetreuer IS NULL AND trim(firmenbetreuer)!='') OR + (vilesci_pruefer IS NULL AND trim(pruefer)!='') OR + (vilesci_vorsitzender IS NULL AND trim(vorsitzender)!='') OR + (vilesci_pruefer1 IS NULL AND trim(pruefer1)!='')) + ORDER BY diplomarbeit_pk + LIMIT 10;"; + + + + +if($result = pg_query($conn_fas, $qry)) +{ + while($row = pg_fetch_object($result)) + { + + + $k++; + if($row->vilesci_zweitbegutachter=='' AND $row->zweitbegutachter!='') + { + echo ""; + echo ""; + echo ""; + echo ""; + $qryselect="SELECT trim(substring(zweitbegutachter from ' [A-ü]*$')) as zweit + FROM diplomarbeit WHERE diplomarbeit_pk='".$row->diplomarbeit_pk."';"; + $resultselect = pg_query($conn_fas, $qryselect); + $rowselect = pg_fetch_object($resultselect); + echo ""; + //echo ""; + echo ""; + echo ""; + echo ""; + } + if(($row->vilesci_betreuer=='' OR $row->vilesci_betreuer==NULL) AND trim($row->betreuer)!='') + { + echo ""; + echo ""; + echo ""; + echo ""; + $qryselect="SELECT trim(substring(betreuer from ' [A-ü]*$')) as zweit + FROM diplomarbeit WHERE diplomarbeit_pk='".$row->diplomarbeit_pk."';"; + $resultselect = pg_query($conn_fas, $qryselect); + $rowselect = pg_fetch_object($resultselect); + echo ""; + echo ""; + echo ""; + echo ""; + } + if(($row->vilesci_firmenbetreuer=='' OR $row->vilesci_firmenbetreuer==NULL) AND trim($row->firmenbetreuer)!='') + { + echo ""; + echo ""; + echo ""; + echo ""; + $qryselect="SELECT trim(substring(firmenbetreuer from ' [A-ü]*$')) as zweit + FROM diplomarbeit WHERE diplomarbeit_pk='".$row->diplomarbeit_pk."';"; + $resultselect = pg_query($conn_fas, $qryselect); + $rowselect = pg_fetch_object($resultselect); + echo ""; + echo ""; + echo ""; + echo ""; + } + if(($row->vilesci_pruefer=='' OR $row->vilesci_pruefer==NULL) AND trim($row->pruefer)!='') + { + echo ""; + echo ""; + echo ""; + echo ""; + $qryselect="SELECT trim(substring(pruefer from ' [A-ü]*$')) as zweit + FROM diplomarbeit WHERE diplomarbeit_pk='".$row->diplomarbeit_pk."';"; + $resultselect = pg_query($conn_fas, $qryselect); + $rowselect = pg_fetch_object($resultselect); + echo ""; + echo ""; + echo ""; + echo ""; + } + if(($row->vilesci_vorsitzender=='' OR $row->vilesci_vorsitzender==NULL) AND trim($row->vorsitzender)!='') + { + echo ""; + echo ""; + echo ""; + echo ""; + $qryselect="SELECT trim(substring(vorsitzender from ' [A-ü]*$')) as zweit + FROM diplomarbeit WHERE diplomarbeit_pk='".$row->diplomarbeit_pk."';"; + $resultselect = pg_query($conn_fas, $qryselect); + $rowselect = pg_fetch_object($resultselect); + echo ""; + echo ""; + echo ""; + echo ""; + } + if(($row->vilesci_pruefer1=='' OR $row->vilesci_pruefer1==NULL) AND trim($row->pruefer1)!='') + { + echo ""; + echo ""; + echo ""; + echo ""; + $qryselect="SELECT trim(substring(pruefer1 from ' [A-ü]*$')) as zweit + FROM diplomarbeit WHERE diplomarbeit_pk='".$row->diplomarbeit_pk."';"; + $resultselect = pg_query($conn_fas, $qryselect); + $rowselect = pg_fetch_object($resultselect); + echo ""; + echo ""; + echo ""; + echo ""; + } + } +} +echo "
FASVilesci
'".$row->zweitbegutachter."'"; + echo ""; + echo ""; + echo "'".$row->diplomarbeit_pk."'
'".$row->betreuer."'"; + echo ""; + echo ""; + echo "
'".$row->firmenbetreuer."'"; + echo ""; + echo ""; + echo "
'".$row->pruefer."'"; + echo ""; + echo ""; + echo "
'".$row->vorsitzender."'"; + echo ""; + echo ""; + echo "
'".$row->pruefer1."'"; + echo ""; + echo ""; + echo "
"; +?> + + \ No newline at end of file