Database Design Manual

Source: Internet
Author: User
Tags visual studio 2010

Based on the Andriod campus online ordering system

Database Design Manual

Report name Campus Online ordering system Database design Manual

Professional Computer Science and technology

Class letter 1201-1 class

Group leader name Xueqing

Crew list Luyuchao zhangwendong Xu Tian

Date 2015.6.13

Tutor Wang Wang

Database Design Manual

First, Introduction

1.1 Purpose of writing

A) The purpose of writing: database table structure design is a very important part of the whole project development, a good database design, can improve the development efficiency, convenient system maintenance, and for the future expansion of the function of the project left room. We write this document description, from all aspects of the online ordering system database design planning, using it to guide the system in various aspects of the database, for the system development programmer, system analyst to provide benchmark documents. We also want to write data design specifications, specification data name, data range, data code and so on. This document is the basis of the project team's joint operations, with the development of norms, program modules and project members between the interface rules, data methods, we have a common working language, a common work platform, so that the entire software development work can be coordinated and orderly.

b) expected readers: project development of all personnel, project reviewers, project testers, instructor teacher Wang.

1.2 background

A) name of the system to be developed: Andriod-based online ordering system;

b) The task of this project is proposed by the teacher to guide the students to discuss the results of the joint;

c) Developer: xueqing Luyuchao zhangwendong Xu Tian

d) Users: school students outside the food stalls

1.3 definition

Here we list the definition of the terminology used in this document, the original phrase of the foreign language first letter group:

Glossary name

Lexical meanings

Note

EC

Electronic commerce abbreviation, e-commerce

Its content contains two aspects: one is the electronic way, the other is the trade activity. E-commerce refers to the use of simple, fast, low-cost electronic means of communication, the buyer and seller do not meet the various business activities.

C

Client/server

Client/server's abbreviation

Sql

SQL (Structured Query Language) is a database query and programming language for accessing data and querying, updating, and managing relational database systems.

Microsoft Visual Studio 2010

Microsoft Visual Studio 2008 is the next-generation development tool for Windows Vista, Office 2007, and Web 2.0, codenamed "Orcas", which is a timely and comprehensive upgrade to Visual Studio 20,051 times. VS2008 introduces more than 250 new features, integrates object, relational data, and XML access, and the language is more concise.

E-r Chart

Entity-contact diagrams, which provide methods for representing entity types, attributes, and relationships to describe the conceptual model of the real world.

Entity-relationship's abbreviation

1.4 References

A) Approved user contract, user demand specification and project development commissioned contracts;

b) "Database Design Manual" (gb8567--88);

c) Sun Jia. Software Engineering-first edition higher Education Press, 2005.7;

Second, the external design

2.1 Identifiers and states

For contact purposes, specify the code, name, or identifier used to uniquely identify the database, and additional descriptive information is also given. If the database belongs to an experiment, is still under test, or is temporarily used, it is to explain this feature and its effective time range.

2.2 The program that uses it

Andriod Mobile Online Ordering software

2.3 Convention

¨ the development environment of this system is:

Database: My SQL 5.0

Compiler: vs Compiler

Operating system: Microsoft Windows 7

Auxiliary software: PS.

¨ Data items used in this project:

In the name, scope, type and other aspects of the Convention see Data dictionary.

2.4 Specialized Guidance

The system uses ADO.NET.NET to implement the interface with the database, which is based on the. NET framework, a bridge between the application and the database, the communication connection to the database, the execution of T-SQL, the description of the functions and characteristics of the ADO.NET.NET in ADO. We also refer to other information, and do not practice the operation.

The data transformation of the application is implemented through the insertion of T-SQL-related information.

The application's data query is implemented through T-SQL-related query statements, and the application operates on its result set.

Other data items, from specialized design documents.

2.5 Support Software

My SQL 5.0,vs2010 Compiler, Windows 7 operating system, Power Designer12.

Third, structural design

3.1 Conceptual Structure Design

Clearly and correctly describe the data forms and linkages reflected in this database:

3.2 Logical Structure Design

3.2.1 Database Design Specifications

Database naming rules: Db_ database name, the first letter of each English word capitalized;

Table naming rules: Table name _info, the first letter of each English word capitalized;

Field naming rules: The first letter of each English word is capitalized;

Field time format: All time formats are in the form of the 2008-12-20 23:23:02

3.3 Physical Structure Design

3.3.1 Data Sheet Design

See Data dictionary.

3.3.2 design of data access

Index the code that often appears in the query;

Index the code of the relationship to which the connection operation is often performed;

For highly updated relational models, there are no indexes defined, such as buyer users, and we don't discuss the design of storage locations because of the immature technology.

3.3.3 Data Integrity Design

a) PRIMARY KEY constraint, non-null value constraint:

User: The user number is the primary key, so this item is not empty

Dish: The menu ID number is the primary key, so this item is not empty

Order: The order ID is the primary key, so this item is not empty

b) FOREIGN KEY constraints:

In the user table, the user name is the foreign key, the dish table in the menu variety class is the foreign key, through the foreign key to establish the link between the table.

c) UNIQUE constraint:

The primary key for each table is defined as uniqueness, for example, for the user, the user's number, and the user name are used to identify the user, so a unique constraint must be established

d) To define a rule:

For example, specify the number of mobile phone number, order time or quantity range.

Iv. Use of Design

4.1 Data Dictionary Design

1 User table (userInfo): User login is required user name and password, so the user data table must contain user name (UserName), password (userpwd) Two information, there are some other user information, such as user rights (administrator or non-administrator). From the functional database table design as shown in table 1.

Table 1 User tables

Column Name

Data type

Length

Primary key

user_id

Int

4

User_name

varchar

50

User_pwd

varchar

50

2 . Menu Information Table (foodinfo): The menu Information table mainly describes the food information, such as: The dish ID number (FOOD_ID), this ID number is automatically generated by the system, the type of dish (Food_k), the name of the dish (food_name), the price of the dish (Food_price) ; The food belongs to the hotel (Food_res). Product Information table detailed description as shown in table 2

Table 2 Menu Information table

Column Name

Data type

Length

Primary key

food_id

Int

4

Yes

Food_k

varchar

50

Food_name

varchar

50

Food_price

Int

50

Food_res

varchar

50

3 . Order form (Foodorderinfo): The order form has a description of the information. Order ID (order_id), order person's name (order_name), subscriber Phone (Order_phone), the restaurant (order_res), order number of meals (order_num), and so on, as shown in table 3:

Table 3 Order Form

Column Name

Data type

Length

Primary key

order_id

Int

4

Yes

Order_name

varchar

50

Order_phone

varchar

50

Order_res

varchar

20

Order_num

varchar

20

4.2 Data Structure Design

Data structure Name

Properties

Food Products

Dish number, price of food, type of dish, name of dish, Dish

User Information

User number, user name, user password

Order

Order number, meal name, number of meals, reservation, contact number

4.3 Security and confidentiality design

The database is the basis of the management system and usually holds important store operating information and customer information. Due to financial management, the integrity and security of the data is particularly important. Once the data in the system is lost, it will take a long time to recover, and sometimes even the information system has to be restarted from the system initialization stage. Daily data backup is an important means to ensure the security of the system. Data backup needs to be done in strict accordance with the pre-established backup and recovery strategy, and to implement backup registration and inspection measures. In addition, the system sets the user's identity to identify whether it is a legitimate user, and requires legitimate users to set their password, to ensure that the user identity is not compromised; The system sets different access levels for different data, restricts access to the data categories and content that can be queried by users, and sets different permissions for different users to distinguish different users. such as the District store chief and the clerk. Specific system configuration should be based on the actual operation of the system to make further adjustments.


Database Design Manual

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.