0% found this document useful (0 votes)
22 views

Database

Uploaded by

Piyush Janoti
Copyright
© © All Rights Reserved
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
22 views

Database

Uploaded by

Piyush Janoti
Copyright
© © All Rights Reserved
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 6
a a co Lae Cm won Language ( sid no - Dawe Defi 2 spss Control LON gBOge SQ semen con be « sees Coane! Lepenge ant 57 of metadata, Data Dictionary | All of these et of rules that define valid | Data Dicionary (2 ll of these i type of command that retrieves rom a database on a server. (®) Data Dictionary Query (@ All of these 7 SRE ce sem 1. The underying software that implemeal ‘0 maintains database DB functions is called data 0) ie (ee () constraint ris (engine \WA%pe wage (DML), design of a t{state of a a. ctionary nese jefine valid ctionary nese at retrieves ctionary nese implement DATABASE CONCEPTS legal empty. val ee i. pty value allowed zee OEmPY kSNULL (ayy ational database consists ofa collec “gyTables (t) Fields Bei (0) Records (d) Keys f js a field in a data Detain of els) hat hers eee (@A foreign Key (0A Brimary Key A Ej An identifier (4) An altemate key Ge Afild in a databose table whose values a (A foreign key (b) A primary key (An identifier (d) An alternate key in a! Bp A software system designed t0 allow the definition, creation, querying, update, and administration of databases, is called (@) Database (b) Data model (@-BMS (@) all of these do, A group of columns serving as a primary key are known 2s___ key (a) Candidate (6) Alternate {Composite (@ Foreign H, Pool of values from where a column draws is value is called __ (@) table (b) attribute: (@ domain: (0) dataset @, The column which has unique rows but is not a primary key key. {@) Candidate () Alternate {2 Composite (a) Foreign BEA key may store NULL values in it (a) Primary key (0) Foreign Key scrote key ©” @ Nonae L The state of a database is called —— fe) data constraint 6 database instance (0 database schema (a) none of these Beery language of a relztional database alle values in all the © is called Ki the Blanks 1, Orga lection of related data tables is called ala teud aie, 2. Collection of logically related records called able fyi » 3, Repet bbl 4. Miomatched muiiple copies ofthe same data ie ealed data bs 5, A QsOu1e is a software program that maintains ae 6. Adatabase sling is a skeleton of design of a asec 7. snapshotstate of 2 database at an instance ip pipes elle datanae 8 tis data about dt ee a tre of command used 0 reve data ro gtobe 11. SQL’s full form is vas 12. Fall form of DDL is. 13, Ful form of DML is 14, Ful form of TCLs ag Gonting ess priory be fected onl. 6 doy 6. A row of a rélation is called a(n) 17. A column of a relation is called a(n) U 18. Number of columns in a relation is called its legnie, ta faa ne dn ie ane 2 20, primary key fe/False Questions when referred in another task for relationship of table is called -—=5. Key. caged system enforces standardised data application programs are written to Sepa oer lebased syst. Data redundancy is rampant in file based systems] Data redundancy may inconsistency. TA a se te dala eter eee i cubee ances ieoaa Organized collection of data is called DBMS, r software that manages and maintains Gucese is alled DEMS "1: All candidate keys are primary Keys. > ‘Alternate keys are not primary keys ‘Arecord isa single ot of related fields in a table In a relational table, each table must have an attribute or a combination of attributes that uniquely identifies each row. In a relational table, each row/column inter section represents a single data value, ead to data Attributes do not have a domain.fe Each primary key is also a candidate key, but there may be candidate keys that are not primary keys. NOTE : Answers for OTQs are given at the end of the book. Solved Problems iat isa database system ? What is its need ? SOLUTION(A database is a collection of inter- related data and a daiabase system is basically a computer based recordkeeping system. A typical file processing system sulfers from some major limitations like data redundancy (duplication of data), data inconsistency, unsharable data, unstandardized data, insecu data, incorrect data etc. On the other hand, database system overcomes all these limita wt a nn tions and ensures continuous efficiency. The advantages provided by a database system are: ( Reduced data redundancy (i) Controlled data inconsistency (ii) Shared data (iv) Standardized data (©) Secured data (vi) Integrated data. ‘Therefore, to have the systems with increased performance and efficiency, the database systems are preferred. ACTICES — 3 5 called ing nother task asic. hey. ised data, |~ written yeriten to file based to data dancy. | lancy.7 1 DBMS, jintains ay ina table. have an utes that an inter- key, but are not cy. The emare: 10: DATABASE CONCEPTS think of disadoany ; Hem 2 What are these >= "8H alg! sowrion. With the formed by database sy A; Security_may be compro, good controls, me arintegrity_may be comprom controls. ae Pinised without: _acixtra hardware may be regu a ined, Ja: Performance overhead may be 5 Ssstem i likely to be compe, Hist tree significant differen S betoeen @ fle! processing system anda DBMS, Ae SOLUTION 1, A_DBMS ‘roduces the amoun redundancy/duplication ee i t based system has many of the dei iaplcated 25 data i store apap ee each application. ADBMS implements standardised formats as data is stored at a central location whereas a file based system has same data stored at ‘multiple locations in different formats. | ‘Adatabase management system is designed to coordinate multiple users accessing, the same data at the same time A file processing system is usually designed allow one or more programs t0 access different data files at the same time. yormation about persons ‘the folowing persons cand thor skills are SeConsiter the database 0 the degree and cardia SOLUTION. A database is to contain in ‘and skills. Ata particular time are represented in the database, Skills Programming ee ‘and Programs Operating and Engineerits For each person, the database contin ea Gets, such as adress. For each SH i identification of the appropriate Ue re, an associated job grade Oe ation, The databnse M80 ach person attended each Course, the assumption is that att ‘mappings or common formats. For example, to prepare a consolidated report about a bank’s performance, data from all department files would be needed, But in file based systems, there is no way to link or map data in different files (no data mapping supported). What is database schema ? SOLUTION. The logical structure and design of a database is called the database schema. Itis the [blueprint or skeleton structure of a database. What is database instance ? SOLUTION. The data stored in database at a particular moment of time (ce, the state of the database at a particular instance of time) is called instance of database. Database schema defines the variable’ declarations in tables that belong to a particular database; the value of these variables ata moment of time is called the instance of that database. For example, in a table namely student in a database fas 100 records today, so we can say that today the database-instance has 100 records. AN What is metadata and data dictionary ? SOLUTION. Metadata is data about data, A data dictionary is a centralized repository of metadata, A data dictionary contains information such as what is in the database (lables, indexes etc), its properties (table structures, data types, formats, constraints etc), \ its users ete. What is database engine ? SOLUTION. A database engine is the underlying, software component (a set of programs) that a DBMS uses to create, read, update and delete data from a database. The database engine has fwo major components ; the storage engine and the query processor. The storage engine writes data to and retrieves data from stable media (@g., disks). The query processor accepts, parses, and executes SQL commands. Explain the property of a relation : Values stored must be atomic. SoLUTION. This property of a relation implies that columns and rows in a relational table cannot contain groups or arrays of values e.g., a 53 spin the property of elton: Poems ‘lde-Define the terms INFORMATICS PRACTICES = Xb row cannot contain sultiple values f0F a vie unter column. Likewise a column in a apts aust have exactly one vale (OF a A Columu’s Vales must be from same domain. so.uTion. This property of a relation implies testa values ina column come are ofthe same Kina. icy from the same domain, egy @ Monthly, Salary column contains only specific wronthly salaries. It never contains other faformation such as comments, status flags, oF i) Relation, (i) Tuple, (ii) attribute, i) degree, (0) cardinality. SOLUTION. ¢-(iy Relation. A relation isa table of a relational database, Which has unordered rows and Columns and it contains non-duplicate rows and columns having atomic values (i Tuple. The rows in a relation are called tuples. (ii Attribute, ‘The columns in a relation are # called attributes. (io) Degree, It refers to the number of columns ot attributes in a relation (table). (0) Cardinality. Itrefers to the number of rows or tuples in a relation (table). 3A Define the terms : (i) Primary Key, (i) Candidate Key, (iii) Alternate Key, (iv) Foreign Key (0) Composite Key. SOLUTION. () Primary Key. Primary Key is a column or group of columns in a table that uniquely jdenhily eraeyacoucin Se z (ii) Candidate Key. itis a set of attributes that uniquely identifies tuples in a table. The, Primary key should be selected from the candidate keys, (ii) Alternate key. It is a column or group of columns in a table that uniquely identifies: every row in that fable. All the keys.from_ the candidate keys, which are not primary ~ key are called an Altemate Key. 10) Foreign Key. Foreign keys are the columns of the table which refer to the primary key of another table. Foreign key creates a relationship between two tables. pecific ‘other lags, oF Tuple, lational ws and splicate values. called tion are columns of rows randidate gn Key, sjumn oF aniquely es that ym the” _ DATABASE CONCEPTS, ssite Key. When a. two or more coluny composite, py the compasite key Psimay x My pon "Database Management Nis) that ws Structured Query Borin a MySOL database ae Reed in Tal A single MySOL esa frany tables at once and aie nai gg of individual records, ~s dn you understand Py MySQL < server ins Pion. MySQL server insane a acaxground processes and applications Bi memory ana Tistns for et rues coring 8 owes fhe network and acress pe contents according fo thase requests Be provides that to the ce pedo you understand by MySQl Fearon. MySOL Clients are Prous Femnect to the MySQL Server and issue queti Gna pre-specified fo SQL is compatible: He standards based Sb Go ‘Query Langueee)- THe client program may emct the server rogrammatically of terms for each of the followin: ‘lection of 1ogicaly res hat omits innit hem Dams creates « fle ttribute that om" if?

You might also like