•  

    400-878-1895px51870017
    葩星1752902151 淘寶旺旺passiontechinc
    sales@www.bkozfdw.com 13296027252
      加載中,請稍候...
    瀏覽歷史

     


    Database相關概念

    關鍵詞: Database相關概念


    簡介:數據管理系統提供最有效的管理方式用于保存數據在一個可靠的,有組織的形式。 This removes the burden of managing data from the application code and provides several key advantages that an application would 其他wise not have access to.Figure2, “保護, 組織, 和共享”depicts many of the risks that a database can help mitigate. Database features are c...
    品 牌
    產 地
    型 號 PXF2639
    折 扣
    咨詢專家:

    產品說明:

    數據管理系統提供最有效的管理方式用于保存數據在一個可靠的,有組織的形式。 This removes the burden of managing data from the application code and provides several key advantages that an application would 其他wise not have access to.

    Figure 2, “保護, 組織, 和共享” depicts many of the risks that a database can help mitigate. Database features are clustered near related risks, and many features are optional because an application is not always susceptible to every risk. The more database features an application utilizes, the better protected it is against nearby risks.

    Protect, Organize, and Share Data to Mitigate Risks

    Figure 2. Protect, Organize, and Share Data to Mitigate Risks

     

    Reliable storage is the primary motivation for using a database. Operations on a database are grouped into transactions, which will either succeed (commit) or fail (abort) as a single unit. Because transactions are persistent, data will not become lost or corrupted even after a power failure. After a crash, data is automatically recovered up to the last committed transaction.

    [Warning] Warning

    A database cannot protect against a corrupted file system or damaged media hardware. Regular backups are the only way to provide full 保護against data loss.

    A database can also provide powerful tools to help organize and access data. The structure of a database is specified in the database schema, which is used as the basis for navigating the data. Data is stored in tables, which contain a list of typed columns. Keys are defined on certain columns of the table to quickly locate rows based on the data stored in the key column. This fast data access through indexed key fields is an important advantage of a database managment system.

    Because data is stored in an organized format, it is possible to perform generic queries on the data. This allows existing software tools to be used with the data stored in the database, regardless of what application it was created with. Data can also be stored in a platform-independent format so that database files can be moved between different operating systems and processor architectures.

    To prevent data inconsistency, it is important to manage how multiple users modify the database at the same time. A database management system provides concurrency support to ensure that transactions commited by multiple users always appear to complete sequentially. This provides shared access to the database in a safe, efficient way.

    4.1. File and Memory Storage

    Where data is stored controls performance and durability.

    A file storage database is saved to disk continuously. Data is organized into large pages to take advantage of block device performance characteristics. The algorithms used to access data in a file storage database offer consistent overall performance, even as the size of the database grows to exceed the size of main memory.

    A memory storage database is stored primarily in memory. Direct pointers are used internally so that individual operations always complete in a predictable amount of time. For this reason, the size of a memory storage database is limited by the size of main memory.

    A hybrid database uses both file and memory storage to store both disk and memory tables in the same database. In this way, applications can balance requirements for durability and performance by creating some tables as memory tables. A hybrid database is created by setting the memory storage size when opening a file storage database.

    [Warning] Warning

    Avoid creating a memory storage that is larger than main memory. Virtual memory page faults will occur frequently in a large memory storage database. Instead, use a file storage and store some or all data in disk tables. The paging algorithms used for disk tables are specifically designed to minimize paging for table data.

    The storage model can be 改變d easily because it does not affect the way that tables are used. The only differences are in:

    • How the application 連接s to the database.

    • Whether tables are created on disk or in memory. For file storage, disk tables are created by default. For memory storage, memory tables are created by default.

    • Performance characteristics.

    • What data is lost when the database is closed or an unexpected failure occurs.

    The fundamental difference between disk and memory storage is the index algorithms used to sort and search for rows. Disk tables use B+ tree indexes, which have a shallow tree structure to minimize disk I/O as depicted in Figure 3, “B+ Tree Index Organization”. Reading a page from disk is an expensive operation and each node in the B+ tree is a page. The organization of a B+ tree ensures that even in a very large table, any key can be located with very few page read operations. The B+ tree contains a full copy of the data in each index column, so that full rows do not need to be loaded from disk when using an index.

    B+ Tree Index Organization

    Figure 3. B+ Tree Index Organization


    Memory tables use T-tree indexes, which have a deep binary tree structure as depicted in Figure 4, “T-Tree Index Organization”. Without disk I/O, traversing the 節點 of the tree is an inexpensive operation. Each node contains pointers to rows in the table rather than a full copy of the index columns.

    T-Tree Index Organization

    Figure 4. T-Tree Index Organization

    4.2. Table Type

    When a table is created, one of several table types can be selected. The table type affects the overhead and performance of storing and accessing data. ITTIA DB SQL™ supports the table types listed in Table 2, “Table Types”. The default table type depends on the storage model used by the database and some storage models do not support all types of tables. The default table type for disk storage is Key Heap, while the default table type for memory storage is Memory.

    Table Type Disk Storage Memory Storage
    Key Heap Table Default Not Supported
    Clustered Table Supported Not Supported
    Memory Table Supported Default

    Table 2. Table Types


    The table type controls how the data is represented inside the database. However, it does not affect how the data is accessed. From an application's perspective, a table is always a collection of rows and columns with zero or more indexes.

    A key heap table uses a hidden 4 byte key to identify each row. Indexes on a key heap table use a copy of this key to locate rows when fetching data, as shown inFigure 5, “Key Heap Table Organization”. One unique index can be designated as the primary key.

    Key Heap Table Organization

    Figure 5. Key Heap Table Organization


    [Tip] Tip

    The overhead of a row in a key heap table uses the following formula: 4 bytes + 2 bytes per column + 12 bytes per index + 2 bytes per index column. This is added to the size of each field that is not null in the table and in each index, which contain a copy of the indexed fields, to get the total size of the row.

    This calculation is valid for the current implementation and is subject to 改變 in future releases.

    A clustered table, shown in Figure 6, “Clustered Table Organization”, groups rows acording to the order specified by an index. This improves performance when accessing a batch of rows with the cluster index because related rows are often stored in the same page. However, 其他 indexes on the same table do not benefit from clustering. The clustering index is specified when the table is created and cannot be 改變d without dropping the table.

    Clustered Table Organization

    Figure 6. Clustered Table Organization


    A clustered table has the following benefits:

    1. Performance is improved for database operations that use the clustering index to fetch a single row or a set of adjacent rows. Because the table and index are combined, such operations avoid an extra index lookup.

    2. Storage overhead is generally reduced.

    A clustered table has a few drawbacks:

    1. The table must have a primary key and the application must provide a value for the primary key whenever a row is inserted. Sequence generators are available for this purpose.

    2. The primary key definition cannot be 改變d without dropping the table.

    The clustering index must meet the following conditions:

    1. The clustered index is the table's primary key.

    2. All index fields are NOT NULL.

    3. No variable-width index field exceeds 255 bytes.

    4. The total size of the index fields is at most (32 - v) bytes, where v is the number of.variable-width index fields.

    [Tip] Tip

    The overhead of a row in a clustered table uses the following formula: 2 bytes per column + 36 bytes per non-clustered index + 2 bytes per non-clustered index column.

    This calculation is valid for the current implementation and is subject to 改變 in future releases.

    The most efficient table type depends on the number of indexes created on the table and the size of the primary key. A clustered table has the most compact representation for a table with only one index or an integer primary key, while a key heap table is more compact when there are many indexes and a large primay key.

    參數資料:
    Database相關概念Database相關概念
    該文章系原廠商文章翻譯,不通之處請參考原文
    價格列表: Database相關概念Database相關概念
    葩星訂貨號 訂貨號 產品名稱 報價 品牌  
    相關產品: Database相關概念Database相關概念
      咨詢歷史:
    欧美成人卡一卡二卡3卡四,凹凸在线导航AV网站,人妻互换一二三区激情视频,国产日产精品国产精品毛片,精品无人区无码乱码毛片国产 67194熟妇人妻欧美日韩| 欧美性猛交XXXX富婆| 卡1卡2卡3卡4卡5免费香蕉| 99国产欧美久久久精品蜜芽| 国产精品一区二区毛卡片| 麻豆国产人免费人成免费视频| 漂亮少妇按摩被中出中文字幕| AV色综合久久天堂AV色综合在| 18禁美女黄网站色大片免费看下| 东北妇女肥胖BBWBBwBBw | 熟妇高潮喷沈阳45熟妇高潮喷 | 东北妇女肥胖BBWBBwBBw | 在线观看Av网站永久免费| 熟妇高潮喷沈阳45熟妇高潮喷 | 在线观看Av网站永久免费| 丰满少妇A级毛片免费168| A片无码一区二区三区在线 | 麻豆国产人免费人成免费视频| 欧美性猛交XXXX富婆| 欧美丰满熟妇XXXX公交车爱爱| 漂亮人妻被黑人久久精品| 中字卡1卡2卡3卡4卡5| 中字卡1卡2卡3卡4卡5| 最爽的乱婬视频a毛片| 四虎影院在线观看| 亚洲v欧美v日韩v国产v麻豆| 欧美老妇与禽另类交| 亚洲v欧美v日韩v国产v麻豆| 欧美大片18禁AAA片免费| 性色高清XXXXX厕所偷拍| 免费A片视频日本一区二区三区 | 日本丰满少妇高潮呻吟| 边吃奶边摸叫床刺激A片视频| 国产精品一区二区毛卡片| 在线无码午夜福利高潮视频| 国产精品视频无码中出| 中字卡1卡2卡3卡4卡5| 东北妇女精品BBwBBW|