Last commit for create.sql: 210f13cfca9dddd407d931fe43d8dc6418c0849d

Updated geworkbench, geworkbench-web

Jonathan Bell [2012-05-16 16:17:47]
Updated geworkbench, geworkbench-web
  1. CREATE TABLE ANALYSISEVENT (ID INTEGER AUTO_INCREMENT NOT NULL, CREATEDAT DATETIME, FINISHEDAT DATETIME, NOTE VARCHAR(255), TRANSACTION_ID INTEGER, TOOL_ID INTEGER, PRIMARY KEY (ID))
  2. CREATE TABLE ANALYSISEVENTPARAMETER (ID INTEGER AUTO_INCREMENT NOT NULL, PARAMETERKEY VARCHAR(255), PARAMETERVALUE VARCHAR(255), EVENT_ID INTEGER, PRIMARY KEY (ID))
  3. CREATE TABLE Friend (ID INTEGER AUTO_INCREMENT NOT NULL, MUTUAL TINYINT(1) default 0, VISIBLE TINYINT(1) default 0, id_1 INTEGER, id_2 INTEGER, PRIMARY KEY (ID))
  4. CREATE TABLE INCOMINGWORKFLOW (ID INTEGER AUTO_INCREMENT NOT NULL, CREATEDAT DATETIME, NAME VARCHAR(255), RECEIVER_ID INTEGER, SENDER_ID INTEGER, WORKFLOW_ID INTEGER, PRIMARY KEY (ID))
  5. CREATE TABLE NETWORK (ID INTEGER AUTO_INCREMENT NOT NULL, NAME VARCHAR(255), owner INTEGER, PRIMARY KEY (ID))
  6. CREATE TABLE SETTING (ID INTEGER AUTO_INCREMENT NOT NULL, data_key VARCHAR(255), data_value VARCHAR(255), PRIMARY KEY (ID))
  7. CREATE TABLE TOOL (ID INTEGER AUTO_INCREMENT NOT NULL, DESCRIPTION VARCHAR(255), MOSTCOMMONPARAMETERS VARCHAR(255), MOSTCOMMONPARAMETERSCOUNT INTEGER, NAME VARCHAR(255), NUMRATING INTEGER, SUMRATING INTEGER, USAGECOUNT INTEGER, WFCOUNTHEAD INTEGER, REPLACEDBY_ID INTEGER, PRIMARY KEY (ID))
  8. CREATE TABLE TOOLSTATCACHE (TOOLID INTEGER NOT NULL, UPDATED DATETIME, MOSTPOPULARBEFORE_ID INTEGER, MOSTPOPULARNEXT_ID INTEGER, PRIMARY KEY (TOOLID))
  9. CREATE TABLE TOOLRATING (ID INTEGER AUTO_INCREMENT NOT NULL, CREATEDAT DATETIME, RATING INTEGER, TOOL_ID INTEGER, CREATOR_ID INTEGER, PRIMARY KEY (ID))
  10. CREATE TABLE TOOLCOMMENT (ID INTEGER AUTO_INCREMENT NOT NULL, COMMENT VARCHAR(255), CREATEDAT DATETIME, CREATOR_ID INTEGER, TOOL_ID INTEGER, PRIMARY KEY (ID))
  11. CREATE TABLE TRANSACTION (ID INTEGER AUTO_INCREMENT NOT NULL, CLIENTID VARCHAR(255), DATASETNAME VARCHAR(255), DATE DATETIME, HOSTNAME VARCHAR(255), IPADDR BIGINT, USER_ID INTEGER, WORKFLOW_ID INTEGER, PRIMARY KEY (ID))
  12. CREATE TABLE registration (ID INTEGER AUTO_INCREMENT NOT NULL, ADDR1 VARCHAR(50), ADDR2 VARCHAR(50), CITY VARCHAR(50), CREATEDAT DATETIME, DATAVISIBILITY INTEGER, EMAIL VARCHAR(50), first_name VARCHAR(50) NOT NULL, INTERESTS LONGTEXT, lab_affiliation VARCHAR(100) NOT NULL, last_name VARCHAR(50) NOT NULL, LOGDATA INTEGER, online_status INTEGER, PASSWORD VARCHAR(50) NOT NULL, PHONE VARCHAR(50), STATE VARCHAR(50), USERNAME VARCHAR(50) NOT NULL, work_title VARCHAR(50), ZIPCODE VARCHAR(7), ROOTFOLDER_ID INTEGER, PRIMARY KEY (ID))
  13. CREATE TABLE taste_users (ID INTEGER AUTO_INCREMENT NOT NULL, hostname VARCHAR(255), registration_id INTEGER, PRIMARY KEY (ID))
  14. CREATE TABLE User_Network (ID INTEGER AUTO_INCREMENT NOT NULL, VERIFIED TINYINT(1) default 0, VISIBLE TINYINT(1) default 0, network_id INTEGER, user_id INTEGER, PRIMARY KEY (ID))
  15. CREATE TABLE USERWORKFLOW (ID INTEGER AUTO_INCREMENT NOT NULL, CREATEDAT DATETIME, NAME VARCHAR(255), FOLDER_ID INTEGER, OWNER_ID INTEGER, WORKFLOW_ID INTEGER, PRIMARY KEY (ID))
  16. CREATE TABLE WORKFLOW (ID INTEGER AUTO_INCREMENT NOT NULL, CREATEDAT DATETIME, NUMRATING INTEGER, SUMRATING INTEGER, USAGECOUNT INTEGER, CREATIONTRANSACTION_ID INTEGER, CREATOR_ID INTEGER, PARENT_ID INTEGER, PRIMARY KEY (ID))
  17. CREATE TABLE WORKFLOWTOOL (ID INTEGER AUTO_INCREMENT NOT NULL, CARDINALITY INTEGER, TOOL_ID INTEGER, WORKFLOW_ID INTEGER, PRIMARY KEY (ID))
  18. CREATE TABLE WORKFLOWRATING (ID INTEGER AUTO_INCREMENT NOT NULL, CREATEDAT DATETIME, RATING INTEGER, WORKFLOW_ID INTEGER, CREATOR_ID INTEGER, PRIMARY KEY (ID))
  19. CREATE TABLE WORKFLOWCOMMENT (ID INTEGER AUTO_INCREMENT NOT NULL, COMMENT VARCHAR(255), CREATEDAT DATETIME, CREATOR_ID INTEGER, WORKFLOW_ID INTEGER, PRIMARY KEY (ID))
  20. CREATE TABLE WORKFLOWFOLDER (ID INTEGER AUTO_INCREMENT NOT NULL, NAME VARCHAR(255), PARENT_ID INTEGER, OWNER_ID INTEGER, PRIMARY KEY (ID))
  21. CREATE TABLE LOGACTION (ID INTEGER AUTO_INCREMENT NOT NULL, CLASSNAME VARCHAR(255), METHODNAME VARCHAR(255), PRIMARY KEY (ID))
  22. CREATE TABLE USAGEEVENT (ID INTEGER AUTO_INCREMENT NOT NULL, CREATEDAT DATETIME, IPADDRESS BIGINT, ACTIONTYPE_ID INTEGER, USER_ID INTEGER, PRIMARY KEY (ID))
  23. CREATE TABLE ALIGNMENT (ID INTEGER AUTO_INCREMENT NOT NULL, COMMENTS VARCHAR(4000), DEFINITION VARCHAR(255), EMBLID VARCHAR(255) NOT NULL UNIQUE, KEYWORDS VARCHAR(2000), PRIMARY KEY (ID))
  24. CREATE TABLE REFERENCE (ID INTEGER AUTO_INCREMENT NOT NULL, AUTHORS VARCHAR(255), LOCATOR VARCHAR(255), TITLE VARCHAR(255), ALIGNMENT_ID INTEGER, PRIMARY KEY (ID))
  25. CREATE TABLE PROTEINSEQUENCE (ID INTEGER AUTO_INCREMENT NOT NULL, ABBREVATION VARCHAR(255), ACCESSIONNO VARCHAR(255) NOT NULL UNIQUE, DESCRIPTION VARCHAR(255), SEQUENCE VARCHAR(4000), PRIMARY KEY (ID))
  26. CREATE TABLE IGNOREDHOST (IP INTEGER NOT NULL, COMMENT VARCHAR(255), PRIMARY KEY (IP))
  27. CREATE TABLE PROTEINSEQUENCE_ALIGNMENT (alignments_ID INTEGER NOT NULL, sequences_ID INTEGER NOT NULL, PRIMARY KEY (alignments_ID, sequences_ID))
  28. ALTER TABLE ANALYSISEVENT ADD CONSTRAINT FK_ANALYSISEVENT_TOOL_ID FOREIGN KEY (TOOL_ID) REFERENCES TOOL (ID)
  29. ALTER TABLE ANALYSISEVENT ADD CONSTRAINT FK_ANALYSISEVENT_TRANSACTION_ID FOREIGN KEY (TRANSACTION_ID) REFERENCES TRANSACTION (ID)
  30. ALTER TABLE ANALYSISEVENTPARAMETER ADD CONSTRAINT FK_ANALYSISEVENTPARAMETER_EVENT_ID FOREIGN KEY (EVENT_ID) REFERENCES ANALYSISEVENT (ID)
  31. ALTER TABLE Friend ADD CONSTRAINT FK_Friend_id_2 FOREIGN KEY (id_2) REFERENCES registration (ID)
  32. ALTER TABLE Friend ADD CONSTRAINT FK_Friend_id_1 FOREIGN KEY (id_1) REFERENCES registration (ID)
  33. ALTER TABLE INCOMINGWORKFLOW ADD CONSTRAINT FK_INCOMINGWORKFLOW_RECEIVER_ID FOREIGN KEY (RECEIVER_ID) REFERENCES registration (ID)
  34. ALTER TABLE INCOMINGWORKFLOW ADD CONSTRAINT FK_INCOMINGWORKFLOW_SENDER_ID FOREIGN KEY (SENDER_ID) REFERENCES registration (ID)
  35. ALTER TABLE INCOMINGWORKFLOW ADD CONSTRAINT FK_INCOMINGWORKFLOW_WORKFLOW_ID FOREIGN KEY (WORKFLOW_ID) REFERENCES WORKFLOW (ID)
  36. ALTER TABLE NETWORK ADD CONSTRAINT FK_NETWORK_owner FOREIGN KEY (owner) REFERENCES registration (ID)
  37. ALTER TABLE TOOL ADD CONSTRAINT FK_TOOL_REPLACEDBY_ID FOREIGN KEY (REPLACEDBY_ID) REFERENCES TOOL (ID)
  38. ALTER TABLE TOOLSTATCACHE ADD CONSTRAINT FK_TOOLSTATCACHE_MOSTPOPULARNEXT_ID FOREIGN KEY (MOSTPOPULARNEXT_ID) REFERENCES TOOL (ID)
  39. ALTER TABLE TOOLSTATCACHE ADD CONSTRAINT FK_TOOLSTATCACHE_MOSTPOPULARBEFORE_ID FOREIGN KEY (MOSTPOPULARBEFORE_ID) REFERENCES TOOL (ID)
  40. ALTER TABLE TOOLRATING ADD CONSTRAINT FK_TOOLRATING_CREATOR_ID FOREIGN KEY (CREATOR_ID) REFERENCES registration (ID)
  41. ALTER TABLE TOOLRATING ADD CONSTRAINT FK_TOOLRATING_TOOL_ID FOREIGN KEY (TOOL_ID) REFERENCES TOOL (ID)
  42. ALTER TABLE TOOLCOMMENT ADD CONSTRAINT FK_TOOLCOMMENT_TOOL_ID FOREIGN KEY (TOOL_ID) REFERENCES TOOL (ID)
  43. ALTER TABLE TOOLCOMMENT ADD CONSTRAINT FK_TOOLCOMMENT_CREATOR_ID FOREIGN KEY (CREATOR_ID) REFERENCES registration (ID)
  44. ALTER TABLE TRANSACTION ADD CONSTRAINT FK_TRANSACTION_USER_ID FOREIGN KEY (USER_ID) REFERENCES registration (ID)
  45. ALTER TABLE TRANSACTION ADD CONSTRAINT FK_TRANSACTION_WORKFLOW_ID FOREIGN KEY (WORKFLOW_ID) REFERENCES WORKFLOW (ID)
  46. ALTER TABLE registration ADD CONSTRAINT FK_registration_ROOTFOLDER_ID FOREIGN KEY (ROOTFOLDER_ID) REFERENCES WORKFLOWFOLDER (ID)
  47. ALTER TABLE taste_users ADD CONSTRAINT FK_taste_users_registration_id FOREIGN KEY (registration_id) REFERENCES registration (ID)
  48. ALTER TABLE User_Network ADD CONSTRAINT FK_User_Network_network_id FOREIGN KEY (network_id) REFERENCES NETWORK (ID)
  49. ALTER TABLE User_Network ADD CONSTRAINT FK_User_Network_user_id FOREIGN KEY (user_id) REFERENCES registration (ID)
  50. ALTER TABLE USERWORKFLOW ADD CONSTRAINT FK_USERWORKFLOW_OWNER_ID FOREIGN KEY (OWNER_ID) REFERENCES registration (ID)
  51. ALTER TABLE USERWORKFLOW ADD CONSTRAINT FK_USERWORKFLOW_WORKFLOW_ID FOREIGN KEY (WORKFLOW_ID) REFERENCES WORKFLOW (ID)
  52. ALTER TABLE USERWORKFLOW ADD CONSTRAINT FK_USERWORKFLOW_FOLDER_ID FOREIGN KEY (FOLDER_ID) REFERENCES WORKFLOWFOLDER (ID)
  53. ALTER TABLE WORKFLOW ADD CONSTRAINT FK_WORKFLOW_PARENT_ID FOREIGN KEY (PARENT_ID) REFERENCES WORKFLOW (ID)
  54. ALTER TABLE WORKFLOW ADD CONSTRAINT FK_WORKFLOW_CREATIONTRANSACTION_ID FOREIGN KEY (CREATIONTRANSACTION_ID) REFERENCES TRANSACTION (ID)
  55. ALTER TABLE WORKFLOW ADD CONSTRAINT FK_WORKFLOW_CREATOR_ID FOREIGN KEY (CREATOR_ID) REFERENCES registration (ID)
  56. ALTER TABLE WORKFLOWTOOL ADD CONSTRAINT FK_WORKFLOWTOOL_TOOL_ID FOREIGN KEY (TOOL_ID) REFERENCES TOOL (ID)
  57. ALTER TABLE WORKFLOWTOOL ADD CONSTRAINT FK_WORKFLOWTOOL_WORKFLOW_ID FOREIGN KEY (WORKFLOW_ID) REFERENCES WORKFLOW (ID)
  58. ALTER TABLE WORKFLOWRATING ADD CONSTRAINT FK_WORKFLOWRATING_WORKFLOW_ID FOREIGN KEY (WORKFLOW_ID) REFERENCES WORKFLOW (ID)
  59. ALTER TABLE WORKFLOWRATING ADD CONSTRAINT FK_WORKFLOWRATING_CREATOR_ID FOREIGN KEY (CREATOR_ID) REFERENCES registration (ID)
  60. ALTER TABLE WORKFLOWCOMMENT ADD CONSTRAINT FK_WORKFLOWCOMMENT_CREATOR_ID FOREIGN KEY (CREATOR_ID) REFERENCES registration (ID)
  61. ALTER TABLE WORKFLOWCOMMENT ADD CONSTRAINT FK_WORKFLOWCOMMENT_WORKFLOW_ID FOREIGN KEY (WORKFLOW_ID) REFERENCES WORKFLOW (ID)
  62. ALTER TABLE WORKFLOWFOLDER ADD CONSTRAINT FK_WORKFLOWFOLDER_PARENT_ID FOREIGN KEY (PARENT_ID) REFERENCES WORKFLOWFOLDER (ID)
  63. ALTER TABLE WORKFLOWFOLDER ADD CONSTRAINT FK_WORKFLOWFOLDER_OWNER_ID FOREIGN KEY (OWNER_ID) REFERENCES registration (ID)
  64. ALTER TABLE USAGEEVENT ADD CONSTRAINT FK_USAGEEVENT_USER_ID FOREIGN KEY (USER_ID) REFERENCES registration (ID)
  65. ALTER TABLE USAGEEVENT ADD CONSTRAINT FK_USAGEEVENT_ACTIONTYPE_ID FOREIGN KEY (ACTIONTYPE_ID) REFERENCES LOGACTION (ID)
  66. ALTER TABLE REFERENCE ADD CONSTRAINT FK_REFERENCE_ALIGNMENT_ID FOREIGN KEY (ALIGNMENT_ID) REFERENCES ALIGNMENT (ID)
  67. ALTER TABLE PROTEINSEQUENCE_ALIGNMENT ADD CONSTRAINT FK_PROTEINSEQUENCE_ALIGNMENT_sequences_ID FOREIGN KEY (sequences_ID) REFERENCES PROTEINSEQUENCE (ID)
  68. ALTER TABLE PROTEINSEQUENCE_ALIGNMENT ADD CONSTRAINT FK_PROTEINSEQUENCE_ALIGNMENT_alignments_ID FOREIGN KEY (alignments_ID) REFERENCES ALIGNMENT (ID)