Database script project design

Source: Internet
Author: User

Objective: To manage database scripts in a project

Requirements:

  1. Script version management
  2. Maintain script execution sequence
    1. Create a table
      1. Create by Table Category in sequence:
        1. Enum table, for example: all countriesCodeTable, ethnic code table. These tables do not depend on other tables
        2. Basic entity tables, such as the employee information table. These tables are basic entities.
        3. Other tables depend on other tables in the preceding table.
      2. Sequence of creating each table
        1. Use create table to create a table
        2. Add constraints (own)
        3. Add foreign key constraints
        4. Insert static initial data (for example, country code)
    2. Create views, functions, and stored procedures: Create one by dependency
  3. Run a script to install or reinstall the entire database.
  4. Execute a script to regenerate a table (including structure, data, constraints, and so on)

 

Database test project

  1. Run a script to generate or regenerate the test data.
  2. Execute a script to automatically test database functions, stored procedures

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.