NC303_UPDATE_DB2.sql 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. --
  2. -- Licensed Materials - Property of IBM
  3. --
  4. -- BI and PM: JSM
  5. --
  6. -- (c) Copyright IBM Corp. 2003, 2010.
  7. --
  8. -- US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  9. --
  10. -------------------------------------------------------------------------------
  11. -- NC303_UPDATE_DB2.SQL *DO NOT EDIT* Data Store Version: 303
  12. -------------------------------------------------------------------------------
  13. -------------------------------------------------------------------------------
  14. --$100-- backup create begin
  15. -------------------------------------------------------------------------------
  16. -------------------------------------------------------------------------------
  17. --$110-- backup inserts begin
  18. -------------------------------------------------------------------------------
  19. -------------------------------------------------------------------------------
  20. --$130-- views drop begin
  21. -------------------------------------------------------------------------------
  22. -------------------------------------------------------------------------------
  23. --$140-- tables drop begin
  24. -------------------------------------------------------------------------------
  25. -------------------------------------------------------------------------------
  26. --$200-- recreate tables begin
  27. -------------------------------------------------------------------------------
  28. CREATE TABLE NC_METRICS(
  29. NAME VARCHAR(255) NOT NULL,
  30. LASTMOD_TIME NUMERIC(19) WITH DEFAULT 0 NOT NULL ,
  31. VALUE NUMERIC(19) WITH DEFAULT 0 NOT NULL,
  32. ACTIVE INTEGER WITH DEFAULT 0 NOT NULL
  33. );
  34. -------------------------------------------------------------------------------
  35. --$202-- primary keys add begin
  36. -------------------------------------------------------------------------------
  37. ALTER TABLE NC_METRICS
  38. ADD CONSTRAINT PN_METRICS PRIMARY KEY (NAME);
  39. -------------------------------------------------------------------------------
  40. --$210-- views create begin
  41. -------------------------------------------------------------------------------
  42. -------------------------------------------------------------------------------
  43. --$220-- server data inserts begin
  44. -------------------------------------------------------------------------------
  45. INSERT INTO NC_DB_VERSION (DB_VERSION_ID,BUILD) VALUES(303,'build no.');
  46. -------------------------------------------------------------------------------
  47. --$230-- restore inserts begin
  48. -------------------------------------------------------------------------------
  49. -------------------------------------------------------------------------------
  50. --$250-- backup drop begin
  51. -------------------------------------------------------------------------------
  52. -------------------------------------------------------------------------------
  53. --$260-- end sql by function
  54. -------------------------------------------------------------------------------
  55. -- END NC303_UPDATE_DB2.SQL * DO NOT EDIT *
  56. -------------------------------------------------------------------------------