daily pastebin goal
59%
SHARE
TWEET

Untitled

a guest Jan 17th, 2019 58 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. DROP TRIGGER IF EXISTS dispatchTrigger;
  2. CREATE TRIGGER IF NOT EXISTS dispatchTrigger
  3. AFTER INSERT ON bestellungenthaltenmahlzeiten
  4. FOR EACH ROW
  5. UPDATE mahlzeiten
  6. SET Vorrat = Vorrat - NEW.Anzahl
  7. WHERE ID = NEW.MahlzeitID;
  8.  
  9. DROP TRIGGER IF EXISTS verfügbarTrigger;
  10. CREATE TRIGGER IF NOT EXISTS verfügbarTrigger
  11. AFTER INSERT ON bestellungenthaltenmahlzeiten
  12. FOR EACH ROW
  13. UPDATE mahlzeiten
  14. SET Verfügbar = 0
  15. WHERE Vorrat = 0;
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top