中央开放教育电大数据库应用技术(本科)形成性考核册答案.doc_第1页
中央开放教育电大数据库应用技术(本科)形成性考核册答案.doc_第2页
中央开放教育电大数据库应用技术(本科)形成性考核册答案.doc_第3页
中央开放教育电大数据库应用技术(本科)形成性考核册答案.doc_第4页
中央开放教育电大数据库应用技术(本科)形成性考核册答案.doc_第5页
已阅读5页,还剩6页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

第一章 思考与练习题一、选择题 1 三级模式间存在两种映射,它们是(C)。A模式与子模式间,模式与内模式间B子模式与内模式间,外模式与内模式间C外模式与模式间,模式与内模式间D模式与内模式间,模式与模式间 2 SQL Server系统中的所有系统级信息存储于哪个数据库( A )。Amaster Bmodel Ctempdb Dmsdb 3 下面关于tempdb数据库描述不正确的是( D )。A是一个临时数据库 B属于全局资源C没有权限限制 D是用户建立新数据库的模板 4 在数据库技术中,面向对象数据模型是一种( B )。A概念模型B结构模型C物理模型D形象模型 5 数据库管理系统常见的数据模型有(B)。A网状、关系和语义B层次、关系和网状C环状、层次和关系D网状、链状和层次 6 用户看到的数据表,属于数据库系统三级模式中的( D )。A外模式B内模式C子模式D模式 7 对数据的插入属于数据库管理系统( B )的功能。A数据定义B数据操纵C数据库的运行管理D数据库的建立和维护 8 保持数据的完整性属于数据库管理系统( C )的功能。A数据定义B数据操纵C数据库的运行管理D数据库的建立和维护 9 在SQL Server数据库中,默认情况下Sys通常是( C )。A数据文件的后缀B事务日志文件的后缀C系统表表名的前缀D辅助文件的后缀二、填空题 1 计算机数据处理技术大致经历了( 人工管理 )、( 文件管理 )、( 数据库管理 )等不同的发展阶段。 2 数据库系统由( 外模式 )、( 模式 )和( 内模式 )三级抽象模式构成。 3 数据库管理系统的主要功能包括( 数据定义 )、( 数据操纵 )、( 数据库的运行管理 )、( 数据库的建立和维护 )。 4 关系模型由三部分组成( 数据结构 )、( 关系操作集合 )和( 关系的完整性 )。 5 SQL Server提供了大量易用的管理工具,比较常用的主要有( 服务管理器 )、( 企业管理器 )和( 查询分析器 )。 6 数据文件的后缀是( mdf )。 7 事务日志文件的后缀是( ldf )。 8 SQL Server数据库分为 ( 系统数据库 )和( 用户数据库 )两种类型。三、简答题1什么是数据和数据处理?数据与信息的区别联系是什么?参考答案:数据(Data)是一组表示数量、行动和目标的非随机的可鉴别的符号。数据处理通常包括查找、统计、分类、修改、计算、汇总等各种方法。数据(Data)是一组表示数量、行动和目标的非随机的可鉴别的符号。信息(Information)是经过加工的,能对接收者的行为和决策产生影响的、有价值的数据。如果将数据比喻为原料,那么信息就是数据经过加工而生产的产品,是有价值的数据。与原料和产品的概念相似,一个系统的产品可能是另一个系统的原料,那么一个系统的信息可能成为另一个系统的数据。2数据库、数据库管理系统、数据库系统之间到底是什么关系?参考答案:数据库就是各种相关数据的集合和容器。数据库所保存的数据是指长期储存在计算机内、有组织的、可共享的数据集合。数据库中的数据必须按一定的数据模型组织、描述和储存,具有较小的冗余度、较高的数据独立性和易扩展性,并可以被一定范围内的各种用户共享。数据库管理系统是对数据库进行管理的系统软件,位于用户和操作系统之间,为用户或应用程序提供访问数据库的方法和工具。广义上,数据库系统就是采用了数据库技术的计算机系统,一般由数据库、数据库管理系统(及其开发工具)、应用系统、数据库管理员和用户构成。狭义上讲,数据库系统主要指数据库和数据库管理系统,由于这二者在应用中的相互依赖性,所以在一般不引起混淆的情况下常常把数据库系统简称为数据库。3请描述一下SQL Server数据库的存储结构。参考答案:SQL Server数据库的存储结构包括物理存储结构和逻辑存储结构两个层面。在物理层面上,SQL Server数据库是由两个操作系统文件组成的,即数据文件和事务日志文件,它们的后缀分别是MDF和LDF。数据文件主要用于存储数据,事务日志文件主要用于存储数据库的更新情况等事务日志信息。在逻辑层次上,数据库是由表、视图、存储过程等一系列数据对象组成的。当采用SQL Server企业管理器将上述数据库文件“打开”后,就能看到数据库的逻辑结构了,如图XXX所示。数据库中的数据分别存储在几个不同的对象中,而这些对象是用户在操作数据库时,实际能够看到和接触到的,属于逻辑存储结构。常用的数据库对象主要包括:表(Table)、索引(Index)、视图(Views)、触发器(Triggers)、存储过程(Store Procedures)、缺省(Default)、约束(Constraints)、用户(Users)以及图表(Diagram)和用户自定义的数据类型等。在以后的章节中,我们将逐步学习这些对象的使用方法。4简述关系模型的组成。参考答案:系模型是目前最重要的一种数据模型。关系数据库系统采用关系模型作为数据的组织方式。关系模型由三部分组成:数据结构、关系操作集合和关系的完整性。数据结构是指在关系模型中,无论是数据还是数据之间的联系都是以二维表(关系)这一种简单的结构表示的,这即符合人们使用数据的习惯,同时也便于计算机实现。关系操作是指关系代数(或等价的关系演算)中并、交、差、选择、投影、连接等。关系模型给出了关系操作的能力和特点,但不对DBMS的语言给出具体的语法要求。关系语言的特点是高度的非过程化。其操作方式的特点是集合操作,即操作的对象和结果是集合,称为一次一集合的方式,而不是一次一个记录的方式。关系完整性包括实体完整性、参照完整性和用户自己定义的完整性。实体完整性是保证数据库中记录的惟一性,即每个记录的主键不能为空值,也不能与其他记录的主键相同。参照完整性是保证表与表之间语意上的完整性,即当一个表引用在另一个表中定义的实体时,要保证这个实体的有效性。这两种完整性是关系模型必须满足的约束条件,应该由关系系统自动支持。而用户自定义完整性反映了用户的要求,是用户自行定义的。第二章思考与练习题一、选择题 1 下述关于索引的描述,正确的是( B )。A撤销索引会同时撤销数据库中与之相关的内容B建立索引后,会影响基本表的插入速度C基本表的记录数量越多,越不应该建立索引D基本表的记录越长,越不应该建立索引 2 下述关于视图的描述,正确的是( C )。A视图仅由一个基本表导出B执行视图比在客户端直接执行SELECT语句的速度要慢C在SQL Server中,可以像基本表一样对视图进行查询操作D视图存储在客户端的数据库中 3 如果希望从学生表中查询出所有姓“张”的同学,那么条件语句应该是( B )。AWhere 姓名 % 张BWhere 姓名 LIKE 张CWhere 姓名 % LIKE张DWhere 姓名 LIKE 张 4 下列SQL语句中,能够完成求某列最大值的是( B )。ASELECT AVG(Age) FROM StudentBSELECT MAX(Age) FROM StudentCSELECT MIN(Age) FROM StudentDSELECT COUNT(*) FROM Student 5假定学生关系S(SNO,SNAME,SEX,AGE),课程关系C(CNO,CNAME,TEACHER),学生选课关系SC(SNO,CNO,GRADE)。要查询选修了“计算机技术”课程的“女”学生姓名,将涉及到关系( D )。AS BSC,C CS,C DS,C,SC二、填空题1SQL数据定义语言的主要作用是创建存储数据的结构,而数据操纵语言的主要作用则是向数据库中填写数据,具体包括 增加、删除、修改 等操作。2当需要对查询结果进行排序时,可以指定其排序方式,字段后使用 ASC 表示升序, DESC 表示降序。3视图是一个虚表,它是从 数据表 中导出的表。三、简答题1、什么是SQL,请简要说明它的组成和特点。参考答案:结构化查询语言,Structured Query Language,简称 SQL,是关系数据库的标准语言。SQL语言共分为四大类:数据定义语言,数据查询语言,数据操纵语言,数据控制语言。它的特点包括:非过程化语言,统一的语言,是所有关系数据库的公共语言。2、索引的作用是什么?SQL Server有哪几类索引,各自的特点是什么?参考答案:索引(Index)提供了一种快速访问数据的途径,索引是在基本表的列上建立的一种数据加对象,索引是为了加速查询速度而创建的。实际的索引通常是这两大类5种方式的组合。(1)单列索引:对基本表的某一单独的列进行索引,是最简单和最常用的索引类型,通常情况下,应对每个基本表的主关键字建立单列索引。(2)惟一索引:一旦在一个或多个列上建立了惟一索引,则不允许在表中相应的列上插入任何相同的取值。使用惟一索引不但能提高查询性能,还可以维护数据的完整性。(3)复合索引:是针对基本表中两个或两个以上列建立的索引。(4)聚集索引:会改变基本表中记录的物理存储顺序。即表中记录的物理排序顺序不再按插入的先后排列,而是根据索引列重新排序。(5)非聚集索引:表中记录的物理顺序与索引顺序不同,表中的记录仍按实际插入的先后顺序排列,不按索引列排序。3、什么是基本表?什么是视图?视图有什么特点?在什么情况下需要创建视图?参考答案:表是一个由行、列组成的二维结构,通常把行称做记录,把列称为字段。视图是由查询数据库表产生的,它其实是一个虚拟的表,它限制了用户能看到和修改的数据。视图的特点是在基本表或其他视图上建立的表,它的结构和内容都来自某个基本表,是依据基本表存在而存在的。删除一个视图时,不会对基本表产生任何影响,但当删除一张基本表时,与之相关联的视图就会自动被删除。如果要限制用户能够看到的数据库中的信息,可以使用视图。4、谓词LIKE的作用是什么?参考答案:确定给定的字符串是否与指定的模式匹配。模式可以包含常规字符和通配符字符。模式匹配过程中,常规字符必须与字符串中指定的字符完全匹配。5、如果创建一个数据库其SQL语句是什么?参考答案:CREATE DATABASE 数据库名称6、存储过程的含义是什么?创建存储过程的SQL语句是什么?参考答案:存储过程(Stored Procedure)是一组预先编译好的,以一种可执行的形式永久地存储在数据中的SQL代码,在master数据库中存储了一些SQL Server事先定义好的系统存储过程,通常以sp_xxxx做为存储过程的名字。当用户创建数据库时,也会自动生成一些事先定义好的存储过程,通常以dt_xxxx做为名字。创建存储过程的SQL语句是:(1)语句格式:CREATE PROCEDURE AS (2)语句功能:创建一个存储过程,多数是指利用SQL Server的Transact-SQL编写的程序。7、什么是事务?举例说明事务处理的作用是什么?参考答案:事务(Transaction)是并发控制的基本单位,它反映了现实世界中需要以一个完整的单位提交的一项工作。SQL Server通过事务机制,将逻辑相关的一组操作捆绑在一起,以便服务器保持数据的完整性。它是SQL复杂程序设计必不可少的内容。事务需要用户根据实际业务规则定义,有一定的难度,但其原理比较简单。举例说,如果我们正在使用UPDATE语句同时对学生表、成绩表中的学号”20030001”改为”20040001”。这个任务需要两条UPDATE语句组成,即:UPDATE 学生表 SET 学号=20040001 WHERE 学号=20030001UPDATE 成绩表 SET 学号=20040001 WHERE 学号=20030001如果在执行完第一个语句后,计算机突然断电,而第二条语句还没来得急执行,数据出现了不一致怎么办?这时候就需要用到SQL的事务控制功能了。 如果使用了SQL Server的事务控制机制,以上两个问题均可获得很了的解决。在使用事务的情况下,SQL Server可以保证,要么所有的记录要么全部处理,要么一行也不处理。如果修改了全部记录的一半时服务器出错了,SQL Server会返回到以前未执行UPDATE操作前的位置,清除它已经修改过的数据,这就是事务处理的作用。8、SQL Server有哪些数据类型,它们的主要用途是什么?参考答案:SQL Server提供了数值型、字符型、日期型、二进制型、位型、双字节型等6大类数据类型。数据类型是数据的一种属性,表示数据所表示信息的类型。任何一种计算机语言都定义了自己的数据类型。9、假设某教学管理数据库有以下三张表,请写出下列问题的SQL语句:学生(学号,姓名,年龄,性别)课程(课程号,课程名,任课教师)成绩(学号,课程号,成绩)(1)如何在SQL Server上创建这三张表;参考答案:学生表:create table 学生表 (学号 char (8) primary Key,姓名 char(8),年龄 int,性别 bit)课程表:create table 课程表 (课程号 char (7) primary Key,课程名 char(20),任课教师 char (8)成绩表:create table 成绩表 (学号 char (8),课程号 char (7),成绩 Numeric (4,2)(2)查询刘峰教师所授课程号,课程名;参考答案:Select课程号, 课程名 from课程表 where任课教师= 刘峰(3)查询年龄大于20岁的所有男同学的学号、姓名;参考答案: Select 学号, 姓名 from 学生表 where 性别=1 and 年龄20(4)查询至少选修了两门课程(含两门)的学生学号;参考答案:select 学号 from 成绩group by 学号having count(学号)=2 (5)查询王文芳同学选修的所有课程的课程号;参考答案:Select 课程号 from 成绩表, 学生表Where学生表.姓名= 王文芳 and 学生表.学号=成绩表.学号(6)查询王文芳同学不学的课程的课程号;参考答案:select 课程号 from 成绩表where 课程号 not in (select 课程号 from 学生表,成绩表 where 学生表.姓名=王文芳 and 学生表.学号=成绩表.学号) (7)查询所有上刘峰老师课程的学生学号;参考答案: Select 学号 from 成绩表,课程表,学生表Where 课程表.任课教师=刘世峰 and 课程表.课程号=成绩表.课程号 and 课程表.学号=成绩表.学号(8)查询所有选修“数据库原理”的学生的学号;参考答案: Select 学号 from 成绩表,课程表where 课程表.课程名=数据库技术 and 课程表.课程号=成绩表.课程号(9)向学生表中插入一条记录(2003001,吴红,21,女);(1表示女,0表示男)参考答案:insert into 学生表 values (2003001,吴红,21,1)(10)删除三张表中所有学号为20020001的学生信息;参考答案:Delete from学生表 where 学号 20020001Delete from学生表 where 学号 20020001(11)把学号为20030002的学生的年龄改为22岁;参考答案: Update 学生表 set 年龄=22 where学号=20030002请您删除一下内容,O(_)O谢谢!2016年中央电大期末复习考试小抄大全,电大期末考试必备小抄,电大考试必过小抄Basketball can make a true claim to being the only major sport that is an American invention. From high school to the professional level, basketball attracts a large following for live games as well as television coverage of events like the National Collegiate Athletic Association (NCAA) annual tournament and the National Basketball Association (NBA) and Womens National Basketball Association (WNBA) playoffs. And it has also made American heroes out of its player and coach legends like Michael Jordan, Larry Bird, Earvin Magic Johnson, Sheryl Swoopes, and other great players. At the heart of the game is the playing space and the equipment. The space is a rectangular, indoor court. The principal pieces of equipment are the two elevated baskets, one at each end (in the long direction) of the court, and the basketball itself. The ball is spherical in shape and is inflated. Basket-balls range in size from 28.5-30 in (72-76 cm) in circumference, and in weight from 18-22 oz (510-624 g). For players below the high school level, a smaller ball is used, but the ball in mens games measures 29.5-30 in (75-76 cm) in circumference, and a womens ball is 28.5-29 in (72-74 cm) in circumference. The covering of the ball is leather, rubber, composition, or synthetic, although leather covers only are dictated by rules for college play, unless the teams agree otherwise. Orange is the regulation color. At all levels of play, the home team provides the ball. Inflation of the ball is based on the height of the balls bounce. Inside the covering or casing, a rubber bladder holds air. The ball must be inflated to a pressure sufficient to make it rebound to a height (measured to the top of the ball) of 49-54 in (1.2-1.4 m) when it is dropped on a solid wooden floor from a starting height of 6 ft (1.80 m) measured from the bottom of the ball. The factory must test the balls, and the air pressure that makes the ball legal in keeping with the bounce test is stamped on the ball. During the intensity of high school and college tourneys and the professional playoffs, this inflated sphere commands considerable attention. Basketball is one of few sports with a known date of birth. On December 1, 1891, in Springfield, Massachusetts, James Naismith hung two half-bushel peach baskets at the opposite ends of a gymnasium and out-lined 13 rules based on five principles to his students at the International Training School of the Young Mens Christian Association (YMCA), which later became Springfield College. Naismith (1861-1939) was a physical education teacher who was seeking a team sport with limited physical contact but a lot of running, jumping, shooting, and the hand-eye coordination required in handling a ball. The peach baskets he hung as goals gave the sport the name of basketball. His students were excited about the game, and Christmas vacation gave them the chance to tell their friends and people at their local YMCAs about the game. The association leaders wrote to Naismith asking for copies of the rules, and they were published in the Triangle, the school newspaper, on January 15,1892. Naismiths five basic principles center on the ball, which was described as large, light, and handled with the hands. Players could not move the ball by running alone, and none of the players was restricted against handling the ball. The playing area was also open to all players, but there was to be no physical contact between players; the ball was the objective. To score, the ball had to be shot through a horizontal, elevated goal. The team with the most points at the end of an allotted time period wins. Early in the history of basketball, the local YMCAs provided the gymnasiums, and membership in the organization grew rapidly. The size of the local gym dictated the number of players; smaller gyms used five players on a side, and the larger gyms allowed seven to nine. The team size became generally established as five in 1895, and, in 1897, this was made formal in the rules. The YMCA lost interest in supporting the game because 10-20 basketball players monopolized a gymnasium previously used by many more in a variety of activities. YMCA membership dropped, and basketball enthusiasts played in local halls. This led to the building of basketball gymnasiums at schools and colleges and also to the formation of professional leagues. Although basketball was born in the United States, five of Naismiths original players were Canadians, and the game spread to Canada immediately. It was played in France by 1893; England in 1894; Australia, China, and India between 1895 and 1900; and Japan in 1900. From 1891 through 1893, a soccer ball was used to play basketball. The first basketball was manufactured in 1894. It was 32 in (81 cm) in circumference, or about 4 in (10 cm) larger than a soccer ball. The dedicated basketball was made of laced leather and weighed less than 20 oz (567 g). The first molded ball that eliminated the need for laces was introduced in 1948; its construction and size of 30 in (76 cm) were ruled official in 1949. The rule-setters came from several groups early in the 1900s. Colleges and universities established their rules committees in 1905, the YMCA and the Amateur Athletic Union (AAU) created a set of rules jointly, state militia groups abided by a shared set of rules, and there were two professional sets of rules. A Joint Rules Committee for colleges, the AAU, and the YMCA was created in 1915, and, under the name the National Basketball Committee (NBC) made rules for amateur play until 1979. In that year, the National Federation of State High School Associations began governing the sport at the high school level, and the NCAA Rules Committee assumed rule-making responsibilities for junior colleges, colleges, and the Armed Forces, with a similar committee holding jurisdiction over womens basketball. Until World War II, basketball became increasingly popular in the United States especially at the high school and college levels. After World War II, its popularity grew around the world. In the 1980s, interest in the game truly exploded because of television exposure. Broadcast of the NCAA Championship Games began in 1963, and, by the 1980s, cable television was carrying regular season college games and even high school championships in some states. Players like Bill Russell, Wilt Chamberlain, and Lew Alcindor (Kareem Abdul-Jabbar) became nationally famous at the college level and carried their fans along in their professional basketball careers. The womens game changed radically in 1971 when separate rules for women were modified to more closely resemble the mens game. Television interest followed the women as well with broadcast of NCAA championship tourneys beginning in the early 1980s and the formation of the WNBA in 1997. Internationally, Italy has probably become the leading basketball nation outside of the United States, with national, corporate, and professional teams. The Olympics boosts basketball internationally and has also spurred the womens game by recognizing it as an Olympic event in 1976. Again, television coverage of the Olympics has been exceptionally important in drawing attention to international teams. The first professional mens basketball league in the United States was the National Basketball League (NBL), which debuted in 1898. Players were paid on a per-game basis, and this league and others were hurt by the poor quality of games and the ever-changing players on a team. After the Great Depression, a new NBL was organized in 1937, and the Basketball Association of America was organized in 1946. The two leagues came to agree that players had to be assigned to teams on a contract basis and that high standards had to govern the game; under these premises, the two joined to form the National Basketball Association (NBA) in 1949. A rival American Basketball Association (ABA) was inaugurated in 1967 and challenged the NBA for college talent and market share for almost ten years. In 1976, this league disbanded, but four of its teams remained as NBA teams. Unification came just in time for major television support. Several womens professional leagues were attempted and failed, including the Womens Professional Basketball League (WBL) and the Womens World Basketball Association, before the WNBA debuted in 1997 with the support of the NBA. James Naismith, originally from Al-monte, Ontario, invented basketball at the International YMCA Training School in Springfield, Massachusetts, in 1891. The game was first played with peach baskets (hence the name) and a soccer ball and was intended to provide indoor exercise for football players. As a result, it was originally a rough sport. Although ten of Naismiths original thirteen rules remain, the game soon changed considerably, and the founder had little to do with its evolution. The first intercollegiate game was played in Minnesota in 1895, with nine players to a side and a final score of nine to three. A year later, the first five-man teams played at the University of Chicago. Baskets were now constructed of twine nets but it was not until 1906 that the bottom of the nets were open. In 1897, the dribble was first used, field goals became two points, foul shots one point, and the first professional game was played. A year later, the first professional league was started, in the East, while in 1900, the first intercollegiate league began. In 1910, in order to limit rough play, it was agreed that four fouls would disqualify players, and glass backboards were used for the first time. Nonetheless, many rules still differed, depending upon where the games were played and whether professionals, collegians, or YMCA players were involved. College basketball was played from Texas to Wisconsin and throughout the East through the 1920s, but most teams played only in their own regions, which prevented a national game or audience from developing. Professional basketball was played almost exclusively in the East before the 1920s, except when a team would barnstorm into the Midwest to play local teams, often after a league had folded. Before the 1930s very few games, either professional or amateur, were played in facilities suitable for basketball or with a perfectly round ball. Some were played in arenas with chicken wire separating the players from fans, thus the word cagers, others with posts in the middle of the floor and often with balconies overhanging the corners, limiting the areas from which shots could be taken. Until the late 1930s, all players used the two-hand set shot, and scores remained low. Baske

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论