clear.sql 910 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. use SN7_SERVER_SCHEMA;
  2. ALTER TABLE UAREPLACEMENTSTRING DROP CONSTRAINT FK_UAREPLAC_REFERENCE_UA
  3. GO
  4. TRUNCATE TABLE UA
  5. GO
  6. TRUNCATE TABLE UAREPLACEMENTSTRING
  7. GO
  8. ALTER TABLE UA DROP CONSTRAINT FK_UA_REFERENCE_UACONFIR
  9. GO
  10. TRUNCATE TABLE UACONFIRMATION
  11. GO
  12. ALTER TABLE REPLACEMENTSTRING DROP CONSTRAINT FK_REPLACEM_REFERENCE_EVENTLOG
  13. GO
  14. TRUNCATE TABLE EVENTLOGREC
  15. GO
  16. TRUNCATE TABLE REPLACEMENTSTRING
  17. GO
  18. TRUNCATE TABLE SESSIONACTION
  19. GO
  20. ALTER TABLE UAREPLACEMENTSTRING ADD CONSTRAINT FK_UAREPLAC_REFERENCE_UA FOREIGN KEY (UAID) REFERENCES UA (UAID) ON DELETE CASCADE
  21. GO
  22. ALTER TABLE UA ADD CONSTRAINT FK_UA_REFERENCE_UACONFIR FOREIGN KEY (UACONFIRMATIONID) REFERENCES UACONFIRMATION (UACONFIRMATIONID)
  23. GO
  24. ALTER TABLE REPLACEMENTSTRING ADD CONSTRAINT FK_REPLACEM_REFERENCE_EVENTLOG FOREIGN KEY (EVENTLOGRECID) REFERENCES EVENTLOGREC (EVENTLOGRECID) ON DELETE CASCADE
  25. GO