Druckdaten zurücksetzen

Standortzuweisung (Wird über Modul "Bescheinigung SO-Zuw." gesammelt gedruckt:

delete 
from stan_printqueue_antrag
where uid in (select uid from stud where hs='K' and Jahrgang='16')
and zuweisung = 'SOZ';


Anträge löschen, nach dem Zuweisen ensteht ein Eintrag in der printqueue:
update stan_printqueue_antrag
  set datum = '0000-00-00 00:00:00'
     ,druckstatus='N'
where saaid in (select saaid 
                  from stan_antrag
                  where uid in (select uid from stud where hs='K' and Jahrgang='16')
               );


SELECT druckstatus, count(*) Anz
 FROM stan_printqueue_antrag
where saaid in (select saaid 
                  from stan_antrag
                  where uid in (select uid from stud where hs='K' and Jahrgang='16')
               )
group by druckstatus;


SELECT *
 FROM stan_printqueue_antrag
where saaid in (select saaid 
                  from stan_antrag
                  where uid in (select uid from stud where hs='K' and Jahrgang='16')
               );
               
