mysql_poll.sql

来自「jetspeed源代码」· SQL 代码 · 共 35 行

SQL
35
字号
## This is a schema for MySQL for 
## the concept of Polls (voting/answer mechanism in Jetspeed)
##
## Please see the Html documentation for more information 
## on this SQL. Equivalent contributions of this for other 
## databases are welcome.

## The default database should be named "Turbine"

## This schema is imported into MySQL with the command:
## mysql Turbine < MySQL_users_roles_permissions.sql


drop table if exists Polls;

create table Polls  (
    POLLID              integer AUTO_INCREMENT PRIMARY KEY,
    TITLE               varchar (255) NOT NULL,
    UNIQUE (TITLE)
);



drop table if exists Answers;

create table Answers  (
    ANSWERID            integer AUTO_INCREMENT PRIMARY KEY,
    POLLID              integer NOT NULL,
    TITLE               varchar (255) NOT NULL,
    COUNT               integer NOT NULL,
    INDEX POLLID_index ( POLLID )
);


⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?