版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)
文檔簡介
1、database and data warehouseswhat is a database?what is a database? a database is a collection of related data items. it is generally stored on secondary storage devices that allow rapid direct access to individual data items. redundancy is minimized; where possible, only a single copy if a data item
2、 exists. the database may be used by many different application systems at once, eliminating the need for separate systems to maintain the data for each application .when a user program inquires if a particular item is in the database, a database management system (dbms) does the actual searching. t
3、he user does not need to be familiar with the format in which the data is stored or the actual physical location of the data.the dbms cerates the database, keeps it up-to-date, and provides reday access to authorized user. database management systems also provide extensive security measures to preve
4、nt unauthorized access. they make it convenient for expressing relationship between related data items and facilitate the design of user application systems. they provide backup and recovery capabilities to prevent against loss or destruction of vital information. they ensure database integrity, tha
5、t is, what is supposed to be in the database is there and what is not supposed to be .isnt. a person called the database administrator determines who may access the database, modify it, add new relationships ,and the like. this is a very important lifeline. the real question in database management s
6、ystems is how to organize information to provide rapid answers to the kinds of questions users are likely to ask. the same data organized differently can yield drama-tidally different access speeds. there common ways are used to structure a database to indicate the relationships among the data items
7、; these are the relational database, the hierarchical data-base, and the network database.hierarchical, network, and relational databases (three principal logical database models)the hierarchical model in a hierarchical database, data records are arranged in a strict parent child relationship. each
8、parent record may have many children, but each child record has exactly one parent. figure 3-1 shows a simple hierarchical database, indicating the relationship between a customer and the orders it has placed with a company. searching a hierarchical database is rapid and convenient as long as it is
9、searched from the top down. ibms ims (information management system) is the most widely used hierarchical dbms. hierarchical dbms are best suited for problems that require a limited number of structure answers that can be specified in advance. once data relationships have been specified, they cannot
10、 easily be changed without a major programming effort. thus, the hierarchical model cannot respond flexibly to changing requests for information.the network model the network database model is best at representing many-to-many relationship among data. in other words, a ”child” can have more than one
11、 “parent”, as figure3-2 illustrates. computer associates idms is a network dbms for computer mainframes.network dbms are more flexible than hierarchical dbms, but access paths must still be specified in advance. there are practical limitations to the number of links, or relationships ,that can be es
12、tablished among records. if they are too numerous, the software will not work efficiently. neither network no hierarchical database management models can easily create new relationships among data elements or new patterns of access without major programming efforts.the relational model in the early
13、1970s the relational database approach was developed to provide a much more user-friendly organization. instead of using complex structures of pointers the relational database stores information simply as tables called relations. these tables are sometimes called flat because the rows of the table r
14、eally are very much the same as the records of a file.each row in a relation is called a record. each column corresponds to a particular field within the record (fields are also called domains).the fields are headed by attributes, which describe the entries in the column. a relational database consi
15、sts of one or more relations. a relational dbms performs three primary operations on relations to form new relations:(1) two relations may be joined (combined).(2) a relational may be projected (some of the columns are extracted form the relations and used to form the columns of the new relation).(3
16、) records may be selected according to various user specified criterias(structured query language) is the most important query language based on the relational model. for instance, a relation named accounts, record bank accounts, their balance, and type might look like: accountsaccountbalancetype173
17、9211700.00checking251101888.00savings heading the columns are the three attributes: account no, balance, and type. below the attributes are the rows, or records. the first row says that account number 173921 has a balance of one thousand and seven hundreds dollars, and it is checking account .suppos
18、e we wanted to know the balance of account 173921.we could ask this query in sql as follows:select balance form accounts where accountno=173921ibms db2 and oracle from the oracle corporation are examples of mainframe relational database management systems. microsoft access is a pc relational databas
19、e management system. (oracle also has a pc version).client-server architecturemany varieties of modern software use a client-server architecture, in which requests by one process (the client) are sent to another process (the server) for execution. database systems are no exception. in the simplest c
20、lient/server architecture, the entire dbms is a server, except for the query interfaces than interact with user and send queries or other commands across to the server. for example, relational systems generally use the sql language for representing requests from the client to the server. the databas
21、e server then sends the answer, in the form of a table or relation, back to the client. the relationship between client and server can get more complex especially when answers are extremely large. there is also a trend to put more work in the client, since the server will be a bottleneck if there ar
22、e many simultaneous database users.new forms of database and data warehousesobject-oriented database object-oriented databases store data as objects that can be automatically retrieved and shared. included in the object are the processing instructions to complete each database transaction. these obj
23、ects can contain various types of data, including sound, graphics, and video as well as traditional data and processing procedures. the objects can be shared and reused. these features of object-oriented databases promises to facilitate software development through reuse and the ability to build new
24、 multimedia application that combine multiple types of data. benefit of odoms is their ability to support application for the world wide web, as described in the focus on technology.object-oriented database are still a relatively new technology and can be much slower than relational systems for hand
25、ing large quantities of data where there is a high volume of transaction processing. hybrid object-relational data bases have been developed that combine the capability of handing large numbers of transactions found in relational dams with the capability of handing complex relationships and new type
26、s of data found in odoms.hypermedia database hypermedia database manage data differently from object oriented dbms. but they can also contain diverse types of data. they store data as “chunks”of information, with each chunk in a separate node. each node can contain traditional numeric or character d
27、ata or wholedocuments ,software programs, graphics, and even full motion video. each node is totally independent-the nodes are not related by a predetermined organization scheme as they are in traditional database. insured, user establishes their own links between nodes. the relationship among nodes
28、 is less structured than in a traditional dbms. searching for information does not have to follow a predetermined organization scheme. users can branch directly form one node to another in any relationship they establish. for instance, a hypermedia database on automobiles might link basic product in
29、formation with descriptive sales brochures, a video showing the automobile in action, and the location of authorized dealers.data warehouses many companies have allowed their data to be stored in many separate systems that are unable to provide a console dated view of information usable company-wide
30、. one way to address this problem is to build a data warehouse.a data warehouse is a database that consolidates data extracted from various production and operational systems into one large organizations core transaction processing systems are reorganized and combined with other information, includi
31、ng historical data so that they can be used for management decision making and analysis. in most cases, the data in the data warehouse can be used for reporting-they can not be updated-so that the performance of the companys underlying operational system is not affected. the focus on problem solving
32、 describes some of the benefits companies have obtained by using data warehouses.data dictionarythe data dictionary (data dictionary) is the record database which and the application procedure yuan data table of contents one kind of user may visit. the initiative data dictionary is refers to when ma
33、kes the revision to the database or the application program structure, its content may the data dictionary which renews automatically by dbms. the passive data dictionary is refers to when the revision must renew its content manually the data dictionary. the data dictionary is a reservation space, a
34、 database, this is uses for the store information database itself. the data dictionary possibly contains information, for example: the database design material, the storage sql procedure, the user jurisdiction, the user statistics, in the database processs information database growth statistics, the
35、 database performance statistics, the data character canonical is in the system each kind of data description set, carries on the main achievement which the detailed data collection and the data analysis obtain. the data dictionary usually includes the data item, the construction of data, the data s
36、tream, the data storage and the treating processes five parts. the data dictionary is about the data information set, is also all element definition set which contains to the data flow graph. composes 1 data stream, 2 data stream components, namely the data element 3 data storages 4 process the data
37、base the important part is the data dictionaries. it deposits has the related information which the database uses, to the user is group of read-only tables. the data dictionary content includes: (1) database all pattern object information, like table, view, bunch, and index and so on. assigns how ma
38、ny spaces, current has used how many spaces and so on. (2) row default value. (3) restraint information integrity. (4) users name. the (5) user and the role the jurisdiction which awards. (6) user visit or use audit information. (7) other produce database information. the database data dictionary is
39、 group of tables and the view structure. they deposit in the system table space. the database data dictionary is not only each database center. moreover to each user is also the very important information. the user may use the sql sentence to visit the database data dictionary.data independence, int
40、egrity, and securitydata independence in database system, each program works with its own view or views of the database. if new fields are added to a database record, the dbms preserves the existing views so that existing programs dont have to be changed. the ability to modify the structure of the d
41、atabase without affecting existing programs that refer to the database is called data independencedata integrity data integrity refers to the accuracy, correctness, or validity of the data in the database. in a database system, data integrity means safeguarding the data against invalid alteration or
42、 destruction. in large on-line database system, data integrity becomes a more server problem.data security data security refers to the protection of a database against unauthorized or illegal access or modification. this usually involves one or more level of password protection that is specified in
43、the data dictionary. for example, a high-level password might allow a user to read from, write to, and modify the database structure, whereas a low-level password might only allow a user to read from the database.usually an audit trail, the recorded history of the modifications to a database, can be
44、 used to identify where and when a database was tampered with and it can also be used to restore the file to its original condition. 數(shù)據(jù)庫和數(shù)據(jù)倉庫1.什么是數(shù)據(jù)庫?數(shù)據(jù)庫就是相關(guān)的數(shù)據(jù)項的集合。它通常被存儲在輔助存儲器上,這些設(shè)備允許快速直接地訪問單個數(shù)據(jù)項。這樣可以做到冗余最小,如果數(shù)據(jù)項存在的話那么它只有一個副本。數(shù)據(jù)庫可被很多不同的應(yīng)用系統(tǒng)使用,因而避免了不同的系統(tǒng)為每一個應(yīng)用而維護一個數(shù)據(jù)庫。當用戶程序需要數(shù)據(jù)庫中的特殊項時,數(shù)據(jù)庫土管理系統(tǒng)(dbms
45、)做實際的搜索。用戶不需要了解數(shù)據(jù)的存儲格式或數(shù)據(jù)的實際物理位置。數(shù)據(jù)庫管理系統(tǒng)建立數(shù)據(jù)庫并不斷更新,為授權(quán)用戶提供方便的訪問方法。數(shù)據(jù)庫管理系統(tǒng)也提供其它的安全措施以防止非授權(quán)訪問。dbms使用相關(guān)數(shù)據(jù)項之間關(guān)系的表示非常方便,使用戶應(yīng)用系統(tǒng)的設(shè)計變得容易。它們提供備份和恢復(fù)功能以防止重要的信息丟失或被破壞。由系統(tǒng)管理員決定誰可以訪問數(shù)據(jù)庫、修改數(shù)據(jù)庫以及增加新的關(guān)系等。這也是非常重要的責任。數(shù)據(jù)庫管理員具有對商業(yè)信息生命線最大的控制權(quán)。數(shù)據(jù)庫管理系統(tǒng)真正的問題是如何組織信息為用戶提出的各種可能的問題提供快速的答案。以不同方式組織的相同數(shù)據(jù)會產(chǎn)生非常不同的訪問速度。為了表明數(shù)據(jù)項之間的關(guān)系,
46、通常有三種方法用于建立數(shù)據(jù)庫:關(guān)系數(shù)據(jù)庫、層次數(shù)據(jù)庫和網(wǎng)狀數(shù)據(jù)庫。2.層次、網(wǎng)狀和關(guān)系數(shù)據(jù)庫(3個主要的邏輯數(shù)據(jù)庫模型)(1) 層次模型 在層次數(shù)據(jù)庫中,數(shù)據(jù)記錄按嚴格的雙親孩子關(guān)系控制。每一個雙親記錄可以有許多孩子,但是每一個孩子只能有一個雙親。圖3-1所示為一個簡單的層次數(shù)據(jù)庫,它顯示了顧客和一家公司的定貨關(guān)系。從上到下搜索一個層次數(shù)據(jù)庫是快捷和方便的。ibm的信息管理系統(tǒng)(ims)是應(yīng)用最廣泛的層次數(shù)據(jù)庫管理系統(tǒng)。層次數(shù)據(jù)庫管理系統(tǒng)最適合于需要有限個能夠提前詳細說明的結(jié)構(gòu)性答案的問題。一旦數(shù)據(jù)關(guān)系被詳細說明,如果沒有強有力的編程支持,它們是不能輕易被修改的。因此,層次模型不能靈活地滿足信
47、息要求改變的情況。(2) 網(wǎng)狀模型 網(wǎng)狀數(shù)據(jù)庫模型最適宜于表示數(shù)據(jù)之間多對多的關(guān)系。換句話說,“孩子”可以有不止一個“雙親”,如圖f-2所示。computer associate的idms就是一個大型計算機的網(wǎng)狀數(shù)據(jù)庫管理系統(tǒng)。網(wǎng)狀數(shù)據(jù)庫管理系統(tǒng)比層次數(shù)據(jù)庫管理系統(tǒng)更加的靈活,但是訪問路徑仍需提前說明。實際應(yīng)用中,記錄之間建立的連接或關(guān)系有一些限制。如果關(guān)系太多的話,軟件將不能有效地工作。在不修改主程序的情況下,網(wǎng)狀和層次數(shù)據(jù)庫管理模型都不能容易的在數(shù)據(jù)元素之間建立新的關(guān)系或新的訪問方式。(3) 關(guān)系模型在20世紀70年代早期發(fā)展關(guān)系數(shù)據(jù)庫是為了提供更多的對用戶友好的組織。關(guān)系數(shù)據(jù)庫簡單地將數(shù)
48、據(jù)存儲為表格(這些表格叫關(guān)系)而沒有采用復(fù)雜的指針結(jié)構(gòu)。這些有時被稱為平面文件,因為表的行同文件的記錄非常相似。關(guān)系中的每一行叫一個記錄。每一列是記錄的一個特殊的域。域?qū)?yīng)以域名開頭,它描述了整個一列。關(guān)系數(shù)據(jù)庫包含一個或多個關(guān)系。一個關(guān)系數(shù)據(jù)庫管理系統(tǒng)對關(guān)系進行以下三種主要的操作以建立新的關(guān)系。(1) 連接兩個關(guān)系(合并)。(2) 擴展一個關(guān)系(從關(guān)系中抽出某幾列用于形成新的關(guān)系的列)。(3) 根據(jù)用戶描述的不同標準選擇記錄。sql(結(jié)構(gòu)查詢語言)是基于關(guān)系模型的最重要的查詢語言。例如,一個叫“賬目”的關(guān)系記錄銀行的賬目,它們的結(jié)余和類型如:賬號結(jié)余類型173921¥1700.00檢查251
49、101¥888.00儲蓄 列的頭是3個域名:賬號、結(jié)余、類型。域名以下是行或記錄。第一行說明賬號173921有1700元的結(jié)余,它是檢查賬號。假設(shè)我們想知道賬號173921的結(jié)余,我們可以用sql發(fā)出請求如下:select balance form accounts where accountno=173921ibm的db2和oracle公司的oracle就是大型計算機關(guān)系數(shù)據(jù)庫管理系統(tǒng)。microsoft的access是個人計算機關(guān)系數(shù)據(jù)庫管理系統(tǒng)。(oracle也有個人計算機版本)。3.客戶/服務(wù)器結(jié)構(gòu) 現(xiàn)代軟件中有很多采用客戶/服務(wù)器結(jié)構(gòu)。在這種結(jié)構(gòu)中一個過程(客戶)的要求發(fā)送給另一個過
50、程(服務(wù)器)去處理,數(shù)據(jù)庫系統(tǒng)也不例外。在最簡單的客戶/服務(wù)器結(jié)構(gòu)中,除了查詢接口外整個數(shù)據(jù)庫管理系統(tǒng)都是服務(wù)器,查詢接口和用戶打交道并且發(fā)送查詢或其他命令給服務(wù)器。例如:關(guān)系系統(tǒng)通常用sql語言來表示從客戶到服務(wù)器的要求。然后數(shù)據(jù)庫服務(wù)器以表或關(guān)系的形式將答案返回給客戶。當答案非常大時,客戶和服務(wù)器的關(guān)系可能會變得復(fù)雜。如果同時有很多數(shù)據(jù)庫用戶,那么服務(wù)器就會成為瓶頸,因此現(xiàn)在也有一種將更多的工作交給用戶的趨勢。4.瀏覽器/服務(wù)器結(jié)構(gòu)b/s(browser/server)結(jié)構(gòu)即瀏覽器和服務(wù)器結(jié)構(gòu)。它是隨著internet技術(shù)的興起,對c/s結(jié)構(gòu)的一種變化或者改進的結(jié)構(gòu)。在這種結(jié)構(gòu)下,用戶工作
51、界面是通過www瀏覽器來實現(xiàn),極少部分事務(wù)邏輯在前端(browser)實現(xiàn),但是主要事務(wù)邏輯在服務(wù)器端(server)實現(xiàn),形成所謂三層3-tier結(jié)構(gòu)。這樣就大大簡化了客戶端電腦載荷,減輕了系統(tǒng)維護與升級的成本和工作量,降低了用戶的總體成本(tco)。以目前的技術(shù)看,局域網(wǎng)建立b/s結(jié)構(gòu)的網(wǎng)絡(luò)應(yīng)用,并通過internet/intranet模式下數(shù)據(jù)庫應(yīng)用,相對易于把握、成本也是較低的。它是一次性到位的開發(fā),能實現(xiàn)不同的人員,從不同的地點,以不同的接入方式(比如lan, wan, internet/intranet等)訪問和操作共同的數(shù)據(jù)庫;它能有效地保護數(shù)據(jù)平臺和管理訪問權(quán)限,服務(wù)器數(shù)據(jù)庫也
52、很安全。5.數(shù)據(jù)庫的新形式和數(shù)據(jù)倉庫(1) 面向?qū)ο蟮臄?shù)據(jù)庫面向?qū)ο蟮臄?shù)據(jù)庫將數(shù)據(jù)作為能自動重新得到和共享的對象存儲。包含在對象中的是完成每一項數(shù)據(jù)庫事務(wù)的處理指令。這些對象可能包含不同類型的數(shù)據(jù),包括傳統(tǒng)的數(shù)據(jù)和處理過程,也包括聲音、圖形和視頻信號等。對象可以共享和重用。面向?qū)ο蟮臄?shù)據(jù)庫的這些特性通過重用和建立新的多媒體應(yīng)用的能力使開發(fā)軟件變得容易,這些應(yīng)用可以將不同類型的數(shù)據(jù)結(jié)合起來。面向?qū)ο髷?shù)據(jù)庫管理系統(tǒng)的好處就是它們支持www應(yīng)用的能力。(2) 超媒體數(shù)據(jù)庫超媒體數(shù)據(jù)庫管理數(shù)據(jù)的方法與面向?qū)ο髷?shù)據(jù)庫管理系統(tǒng)不同而且它也可能包含不同類型的數(shù)據(jù)。它們將數(shù)據(jù)按信息“塊”存儲,每一塊在一個單獨的節(jié)點里。每一個節(jié)點可能包含傳統(tǒng)的數(shù)字、字符數(shù)據(jù)或整個文檔、軟件
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
- 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2024物流倉儲合同
- 2024年跨國商品銷售合同及其附件
- 二零二五版酒店式公寓租賃合同(含家政服務(wù))下載3篇
- 第三人民醫(yī)院肉類配送服務(wù)合同(含冷鏈運輸及質(zhì)量控制)二零二五年度3篇
- 2025年度智慧城市建設(shè)承包協(xié)議模板3篇
- 2025版五星酒店廚師長職位競聘與聘用合同3篇
- 2025年度旅游景區(qū)場地承包使用權(quán)合同3篇
- 2025年度林業(yè)土地經(jīng)營權(quán)入股合同范本4篇
- 高校二零二五年度科研項目管理聘用合同3篇
- 2024年:知識產(chǎn)權(quán)保護合同2篇
- 第22單元(二次函數(shù))-單元測試卷(2)-2024-2025學年數(shù)學人教版九年級上冊(含答案解析)
- 安全常識課件
- 河北省石家莊市2023-2024學年高一上學期期末聯(lián)考化學試題(含答案)
- 小王子-英文原版
- 新版中國食物成分表
- 2024年山東省青島市中考生物試題(含答案)
- 河道綜合治理工程技術(shù)投標文件
- 專題24 短文填空 選詞填空 2024年中考英語真題分類匯編
- 再生障礙性貧血課件
- 產(chǎn)后抑郁癥的護理查房
- 2024年江蘇護理職業(yè)學院高職單招(英語/數(shù)學/語文)筆試歷年參考題庫含答案解析
評論
0/150
提交評論