资源描述:
《数据库系统原理(英文)-3ppt》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、PART2RELATIONALDATABASESChapter3SQLFunctionsandUsageofSQLdatadefinition:§3.2,DDLdataquery/retrieve:§3.3——§3.8,Selectclausedatamanipulation:§3.9ModificationoftheDatabaseThreePartsinChapter3March20083DatabaseSystemConcepts-Chapter3SQL-Databasequerylanguagescommercialimplementationofr
2、elationaloperationsinDBSinteractivetoolsforuserstodevelop,use/access,andmaintainDBSDBSaccess:create,retrieval,insert,delete,update,etc“Query”generalizeddefinitiondefine,retrieve,modify,controletc.onDB§3.1BackgroundMarch20084DatabaseSystemConcepts-Chapter3SQL-SQLStructuredQueryLanguag
3、eonthebasisoftherelationalalgebraandthetuplerelationalcalculusfirstimplementedinSystemRbyIBMin1970sstandardizedbyANSIandISO,SQL-86,SQL-89,SQL-92,SQL-99,OO-SQL,themostrecentversionisSQL-2003widelyusedforcommercialDBS3.1Background(cont.)March20085DatabaseSystemConcepts-Chapter3SQL-Part
4、s/functionsofSQLdatadefinitionlanguage(DDL)define,delete,modifyonschemas,viewsandindexinteractivedata-manipulationlanguage(DML)query/retrieve,insert,delete,updateontuplesinDBdatacontrolintegrityconstraintsspecifyingauthorization:securitycontrol,specifyingaccessrightstransactionmanage
5、mentembeddedanddynamicSQL3.1Background(cont.)March20086DatabaseSystemConcepts-Chapter3SQL-9basicoperatorsinSQL3.1Background(cont.)datamanipulationSelect(onrelations)Insert,Delete,Update(onrelations)datadefinitionCreate,Drop,Alter(onschema)datacontrolGrant,Revoke(inChapter4)March20087
6、DatabaseSystemConcepts-Chapter3SQL-Casestudyusedinthischapterreturn3.1Background(cont.)Fig.3.1SchemaofbankingenterpriseMarch20088DatabaseSystemConcepts-Chapter3SQL-DDLinSQLallowsthespecificationofinformationabouteachrelation,includingtheschemaforeachrelationorview-----createtable/vie
7、wthedomainofvaluesassociatedwitheachattributeintegrityconstraintsthesetofindicestobemaintainedforeachrelationssecurityandauthorizationinformationforeachrelationthephysicalstoragestructureofeachrelationondisk3.2.1BasicDomainTypeschar(n),varchar(n),int,smallint,numeric(p,d),real,double
8、precision,fl