Design of the EDM program MySQL database

Source: Internet
Author: User

\ \ Customer Attributes

CREATE TABLE ' users ' (
' id ' int (one) not NULL auto_increment COMMENT ' number ',
' Name ' varchar (255) Default NULL COMMENT ' Customer name ',
' Age ' int (3) COMMENT default NULL ' ages ',
' Gender ' int (2) Default ' 0 ' COMMENT ' sex: 0 male 1 female, defaults to zero ',
' Birthday ' datetime default NULL COMMENT ' birthday ',
' Mobile ' varchar (255) Default NULL COMMENT ' mobile phone ',
' Email ' varchar (255) default null NOT NULL COMMENT ' e-mail ',
' IP ' varchar (255) Default NULL COMMENT ' IP ',
' Address ' varchar (255) Default NULL COMMENT ' addresses ',
' Source ' varchar (255) Default NULL COMMENT ' source ',
PRIMARY KEY (' id '),
UNIQUE KEY ' email ' (' email ')
) Engine=innodb auto_increment=1 DEFAULT Charset=utf8;

\ \ Send Statistics

CREATE TABLE ' Sendcount ' (
' id ' int (one) not NULL auto_increment COMMENT ' number ',
' Sendtime ' varchar (255) Default NULL COMMENT ' Send Time ',
' active_id ' int (5) Default NULL COMMENT ' Activity id ',
' customer_id ' int (5) Default NULL COMMENT ' Customer ID ',
PRIMARY KEY (' id ')
) Engine=innodb auto_increment=1 DEFAULT Charset=utf8;

\ \ Activity Table
CREATE TABLE ' doings ' (
' id ' int (one) not NULL auto_increment COMMENT ' number ',
' ProjectID ' int (5) Default NULL COMMENT ' Project ID ',
' typeID ' int (5) Default NULL COMMENT ' type ID ',
' Senddate ' datetime default NULL COMMENT ' Send Date ',
' Againdate ' datetime default NULL COMMENT ' unblock date ',
' Area ' varchar (#) Default NULL COMMENT ' applicable region ',
PRIMARY KEY (' id ')
) Engine=innodb auto_increment=1 DEFAULT Charset=utf8;


\ Open Letter Click on the Activity association table
CREATE TABLE ' openemail_clickdoing ' (
' id ' int (one) not NULL auto_increment COMMENT ' number ',
' open_id ' int (5) Default NULL COMMENT ' open letter id ',
' click_id ' int (5) Default NULL COMMENT ' click id ',
' active_id ' int (5) Default NULL COMMENT ' Activity id ',
PRIMARY KEY (' id ')
) Engine=innodb auto_increment=1 DEFAULT Charset=utf8;


\ \ Record Jump
CREATE TABLE ' Recordjump ' (
' id ' int (one) not NULL auto_increment COMMENT ' association table ID ',
' Jump_url ' varchar (255) Default NULL COMMENT ' record jump ',
' active_id ' int (5) Default NULL COMMENT ' Activity id ',
PRIMARY KEY (' id ')
) Engine=innodb auto_increment=1 DEFAULT Charset=utf8;


\ \ Open Letter Statistics
CREATE TABLE ' Openmailcount ' (
' id ' int (one) not NULL auto_increment COMMENT ' association table ID ',
' IP ' varchar (255) COMMENT ' IP ',
' Open_time ' varchar (255) Default NULL COMMENT ' open letter Time ',
' Open_code ' varchar (255) Default NULL COMMENT ' open letter address ',
' Open_email ' varchar (255) Default NULL COMMENT ' open letter email ',
PRIMARY KEY (' id ')
) Engine=innodb auto_increment=1 DEFAULT Charset=utf8;

\ \ Click Statistics
CREATE TABLE ' Clickcount ' (
' id ' int (one) not NULL auto_increment COMMENT ' association table ID ',
' Click_time ' varchar (255) Default NULL COMMENT ' click Time ',
' Click_code ' varchar (255) Default NULL COMMENT ' click Address ',
' Click_email ' varchar (255) Default NULL COMMENT ' Click Email ',
' IP ' varchar (255) COMMENT ' IP ',
PRIMARY KEY (' id ')
) Engine=innodb auto_increment=1 DEFAULT Charset=utf8;

















Design of the EDM program MySQL database

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.