[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/jettisonJava/APIJSON-Demo/master/PostgreSQL/postgres_sys_ddl.sql [Back]  [Original]

create table "Praise"
(
);

alter table "Praise"
    owner to postgres;

create table "Random"
(
);

alter table "Random"
    owner to postgres;

create table "_Visit"
(
);

alter table "_Visit"
    owner to postgres;

create table "Method"
(
);

alter table "Method"
    owner to postgres;

create table "Document"
(
    id              bigint,
    debug           smallint,
    "userId"        bigint,
    "testAccountId" bigint,
    version         smallint,
    name            varchar(100),
    type            varchar(5),
    url             varchar(250),
    request         text,
    apijson         text,
    sqlauto         text,
    standard        text,
    header          text,
    date            timestamp,
    detail          text
);

alter table "Document"
    owner to postgres;

create table apijson_privacy
(
    id             bigint         not null
        primary key,
    certified      smallint       not null,
    phone          varchar(64)    not null,
    balance        numeric(10, 2) not null,
    _password      varchar(20)    not null,
    "_payPassword" varchar(32)    not null
);

comment on table apijson_privacy is '\n Privacy';

comment on column apijson_privacy.id is '';

comment on column apijson_privacy.certified is '';

comment on column apijson_privacy.phone is ' 11  +86  VARCHAR(14)';

comment on column apijson_privacy.balance is '';

comment on column apijson_privacy._password is '';

comment on column apijson_privacy."_payPassword" is '';

alter table apijson_privacy
    owner to postgres;

create index "phone_UNIQUE"
    on apijson_privacy (phone);

create table apijson_user
(
    id              bigint   not null
        primary key,
    sex             smallint not null,
    name            varchar(20),
    tag             varchar(45),
    head            varchar(300),
    "contactIdList" jsonb,
    "pictureList"   jsonb,
    date            timestamp(6)
);

comment on table apijson_user is ' User';

comment on column apijson_user.id is '';

comment on column apijson_user.sex is '
0-
1-';

comment on column apijson_user.name is '';

comment on column apijson_user.tag is '';

comment on column apijson_user.head is 'url';

comment on column apijson_user."contactIdList" is 'id';

comment on column apijson_user."pictureList" is '';

comment on column apijson_user.date is '';

alter table apijson_user
    owner to postgres;

create table "Comment"
(
    id         bigint           not null
        primary key,
    "toId"     bigint default 0 not null,
    "userId"   bigint           not null,
    "momentId" bigint           not null,
    date       timestamp(6),
    content    varchar(1000)    not null
);

comment on table "Comment" is '';

comment on column "Comment".id is '';

comment on column "Comment"."toId" is 'id';

comment on column "Comment"."userId" is 'id';

comment on column "Comment"."momentId" is 'id';

comment on column "Comment".date is '';

comment on column "Comment".content is '';

alter table "Comment"
    owner to postgres;

create table "Moment"
(
    id                 bigint not null
        primary key,
    "userId"           bigint not null,
    date               timestamp(6),
    content            varchar(300),
    "praiseUserIdList" jsonb  not null,
    "pictureList"      jsonb  not null
);

comment on table "Moment" is '';

comment on column "Moment".id is '';

comment on column "Moment"."userId" is 'id';

comment on column "Moment".date is '';

comment on column "Moment".content is '';

comment on column "Moment"."praiseUserIdList" is 'id';

comment on column "Moment"."pictureList" is '';

alter table "Moment"
    owner to postgres;

create table "TestRecord"
(
    id              bigint                                 not null
        primary key,
    "userId"        bigint                                 not null,
    "documentId"    bigint                                 not null,
    response        text                                   not null,
    date            timestamp(6) default CURRENT_TIMESTAMP not null,
    compare         text,
    standard        text,
    "randomId"      bigint       default 0,
    headless        smallint     default 0                 not null,
    "reportId"      bigint       default 0                 not null,
    "testAccountId" bigint       default 0                 not null,
    duration        bigint       default 0                 not null,
    "minDuration"   bigint       default 0                 not null,
    "maxDuration"   bigint       default 0                 not null,
    host            varchar(200)
);

comment on column "TestRecord".id is '';

comment on column "TestRecord"."userId" is 'id';

comment on column "TestRecord"."documentId" is 'id';

comment on column "TestRecord".response is 'JSON';

comment on column "TestRecord".date is '';

comment on column "TestRecord".compare is '';

comment on column "TestRecord".standard is 'response  JSON  AST  Response  ';

comment on column "TestRecord"."randomId" is ' id';

comment on column "TestRecord".headless is ' UI  Headless 0- 1-';

comment on column "TestRecord"."reportId" is ' ID';

comment on column "TestRecord"."testAccountId" is ' id';

alter table "TestRecord"
    owner to postgres;

create table "Function"
(
    id           bigint                                 not null
        primary key,
    language     varchar,
    name         varchar(30)                            not null,
    "returnType" varchar(45)  default 'Object'::character varying,
    arguments    varchar(100),
    demo         text                                   not null,
    detail       varchar(1000),
    date         timestamp(6) default CURRENT_TIMESTAMP not null,
    "userId"     bigint       default 0,
    version      integer      default 0,
    tag          varchar,
    methods      varchar,
    return       integer
);

comment on column "Function".language is 'Java(java), JavaScript(js), Lua(lua), Python(py), Ruby(ruby), PHP(php) NULL  JavaJDK 1.6-11  JavaScriptJDK 12+  Nashron/Rhiro  js  ScriptEngineManager ';

comment on column "Function".name is '';

comment on column "Function"."returnType" is '';

comment on column "Function".arguments is ' String
 ,   [JSONArray]  array,item ';

comment on column "Function".demo is '';

comment on column "Function".detail is '';

comment on column "Function".date is '';

comment on column "Function"."userId" is 'id';

comment on column "Function".version is 'GET,HEAD\nTODO  requestIdList  version,tag,methods';

comment on column "Function".tag is '.\nnull - \nTODO  requestIdList  version,tag,methods';

comment on column "Function".methods is '\nnull - \nTODO  requestIdList  version,tag,methods';

comment on column "Function".return is '';

alter table "Function"
    owner to postgres;

create table "Request"
(
    id        bigint,
    debug     smallint,
    version   smallint,
    method    varchar(10),
    tag       varchar(30),
    structure json,
    detail    varchar(10000),
    date      timestamp
);

alter table "Request"
    owner to postgres;

create table "Script"
(
    id              bigint,
    "userId"        bigint,
    "testAccountId" bigint,
    "documentId"    bigint,
    simple          smallint,
    ahead           smallint,
    title           varchar(100),
    name            varchar(100),
    script          text,
    date            timestamp,
    detail          varchar(1000)
);

alter table "Script"
    owner to postgres;

create table "Access"
(
    id     integer                                                                                  not null
        primary key,
    schema varchar(100) default NULL::character varying,
    debug  integer      default 0                                                                   not null,
    name   varchar(50)  default ' apijson_user'::character varying                     not null,
    alias  text,
    get    text         default '["UNKNOWN", "LOGIN", "CONTACT", "CIRCLE", "OWNER", "ADMIN"]'::text not null,
    head   text         default '["UNKNOWN", "LOGIN", "CONTACT", "CIRCLE", "OWNER", "ADMIN"]'::text not null,
    gets   text         default '["LOGIN", "CONTACT", "CIRCLE", "OWNER", "ADMIN"]'::text            not null,
    heads  text         default '["LOGIN", "CONTACT", "CIRCLE", "OWNER", "ADMIN"]'::text            not null,
    post   text         default '["OWNER", "ADMIN"]'::text                                          not null,
    put    text         default '["OWNER", "ADMIN"]'::text                                          not null,
    delete text         default '["OWNER", "ADMIN"]'::text                                          not null,
    date   text         default CURRENT_TIMESTAMP                                                   not null,
    detail text
);

comment on column "Access".id is '';

comment on column "Access".debug is '';

comment on column "Access".alias is ' User';

comment on column "Access".get is ' get  ["LOGIN", "CONTACT", "CIRCLE", "OWNER"]
 JSON  JSONArray
TODO:  LOGIN,CONTACT,CIRCLE,OWNER ';

comment on column "Access".head is ' head  ["LOGIN", "CONTACT", "CIRCLE", "OWNER"]';

comment on column "Access".gets is ' gets  ["LOGIN", "CONTACT", "CIRCLE", "OWNER"]';

comment on column "Access".heads is ' heads  ["LOGIN", "CONTACT", "CIRCLE", "OWNER"]';

comment on column "Access".post is ' post  ["LOGIN", "CONTACT", "CIRCLE", "OWNER"]';

comment on column "Access".put is ' put  ["LOGIN", "CONTACT", "CIRCLE", "OWNER"]';

comment on column "Access".delete is ' delete  ["LOGIN", "CONTACT", "CIRCLE", "OWNER"]';

comment on column "Access".date is '';

alter table "Access"
    owner to postgres;

create table "Verify"
(
    id     bigint,
    type   integer,
    phone  bigint,
    verify integer,
    date   timestamp
);

alter table "Verify"
    owner to postgres;


Web Proxy Viewer  |  New URL  |  Original Page