Untitled

mail@pastecode.io avatar
unknown
plain_text
20 days ago
2.1 kB
4
Indexable
Never
-- SCHEMA

USE `SCHEMA`;

CREATE TABLE PERSPECTIVES_FINANCIAL (

    finance_id                                      INT         NOT NULL auto_increment,
    total_sales_from_orders                         FLOAT       NOT NULL,
    total_sales_from_services                       FLOAT       NOT NULL,
    total_sale_from_orders_in_repeat_cust           FLOAT       NOT NULL,
    total_sale_from_services_in_repeat_cust         FLOAT       NOT NULL,

    PRIMARY KEY (finance_id)
);


CREATE TABLE PERSPECTIVES_CUSTOMER (

    cust_id                                         INT         NOT NULL auto_increment,
    total_number_new_cust                           INT         NOT NUll,
    total_number_repeat_cust                        INT         NOT NULL,
    ave_satisfaction_rate                           DOUBLE      NOT NULL,

    PRIMARY KEY (cust_id)
);


CREATE TABLE PERSPECTIVES_INTERNAL_PROCESS (

    int_proc_id                                     INT         NOT NULL auto_increment,
    turn_around_days                                INT         NOT NULL,

    PRIMARY KEY (int_proc_id)
);


CREATE TABLE PERSPECTIVES_ORGANIZATION_CAPABILITY (

    org_cap_id                                      INT         NOT NULL auto_increment,
    LONGEVITY                                       INT         NOT NULL,

    PRIMARY KEY (org_cap_id)
);


CREATE TABLE PERSPECTIVES_DOMAIN_DIMENSIONS (

    domain_dd_id                                    INT             NOT NULL auto_increment,
    operations_region                               VARCHAR(255)    NOT NULL,
    salesRepresentative 							INT(3)			NOT NULL,
    customer_region                                 VARCHAR(255)    NOT NULL,

    PRIMARY KEY (domain_dd_id)
);


CREATE TABLE TIME_DIMENSIONS (

    time_dd_id                                      INT         NOT NULL auto_increment,
    month                                           INT         NOT NULL,
    quarter                                         INT         NOT NULL,
    year                                            INT 		NOT NULL,

    PRIMARY KEY (time_dd_id)
);
Leave a Comment