Quiz
DatabaseInIS
Erstelle ein kostenloses Konto, um dieses Quiz zu beenden
Speichere deinen Fortschritt und sieh dir dein Endergebnis an.
oder mit deiner E-Mail registrieren
Schon ein Konto? Anmelden
Fragen in diesem Quiz (180)
11. Define a degree of a relation
- AHow many rows a table has
- Bhow long each tuple is, or how many columns the table has
- Chow many different tuples there are
- Dhow many different datatypes table has
22. Define a cardinality of a relation
- A• how long each tuple is
- B• how many columns the table has
- C• how many different tuples there are, how many rows a table has
- D• how many different datatypes table has
33. Which of the following refers to union-compatibility requirements ?
- A• Same number of columns
- B• Same number of rows
- C• Same number of tuples
- D• Different domains
44. Which of the following refers to union-compatibility requirements ?
- A• Corresponding columns have the same domains
- B• Same number of rows
- C• Same number of tuples
- D• Corresponding columns have the same fields
55. Define a domain
- A• restrict the possible values a tuple can assign to each attribute
- B• relations to each other
- C• uniquely identifies each tuple that appears in a relation
- D• minimality of the attribute
66. Define a foreign key
- A• restrict the possible values a tuple can assign to each attribute
- B• relations to each other
- C• uniquely identifies each tuple that appears in a relation
- D• minimality of the attribute
77. Define a primary key
- A• restrict the possible values a tuple can assign to each attribute
- B• relations to each other
- C• uniquely identifies each tuple that appears in a relation
- D• datatypes of attributes
88. Define restrict
- A• stop the user from doing it
- B• let the changes flow on
- C• make referencing values the default for their column
- D• make referencing values null
99. Define cascade
- A• stop the user from doing it
- B• let the changes flow on
- C• make referencing values the default for their column
- D• make referencing values null
1010. Define set default
- A• stop the user from doing it
- B• let the changes flow on
- C• make referencing values the default for their column
- D• make referencing values null
1111. Define set null
- A• stop the user from doing it
- B• let the changes flow on
- C• make referencing values the default for their column
- D• make referencing values null
1212. Define Data Definition Language
- A• Specify database format
- B• Specify access controls (privileges)
- C• Specify and retrieve database contents
- D• Specify table attribute uniqueness
1313. Define Data Control Language
- A• Specify database format
- B• Specify access controls (privileges)
- C• Specify and retrieve database contents
- D• Specify table attribute uniqueness
1414. Define Data Manipulation Language
- A• Specify database format
- B• Specify access controls (privileges)
- C• Specify and retrieve database contents
- D• Specify table attribute uniqueness
1515. Which of the following does not refer to DBMS tools
- A• Oracle
- B• PostgreSQL
- C• MySQL
- D• Python
1616. Which of the following is used to provide privilege to only a particular attribute?
- A• Grant select on employee to finance
- B• Grant update(salary, rate) on employee to finance
- C• Grant update(salary) on employee to finance
- D• Grant delete to finance
1717. Which of the following statement is used to remove the privilege from the user finance?
- A• Remove update on employee from finance
- B• Delete select on employee from finance
- C• Revoke update on employee from finance
- D• Grant update on employee from finance
1818. Which of the following is true regarding views? (same answers in base, fixed here)
- A• The user who creates a view cannot be given update authorization on a view without having update authorization on the relations used to define the view.
- B• The user who creates a view cannot be given update authorization on a view without having update authorization on the relations used to define the request.
- C• If a user creates a view on which no authorization can be granted, the system will allow the view creation request.
- D• A user who creates a view receives all privileges on that view.
1919. If we wish to grant a privilege and to allow the recipient to pass the privilege on to other users, we append the clause to the appropriate grant command.
- A• With grant
- B• Grant user
- C• With grant option
- D• Grant pass privelege
2020. Which of the following is used to avoid cascading of authorizations from the user?
- A• Granted by current role
- B• Revoke grant option for select on department from finance;
- C• Revoke select on employee from finance, cashier restrict;
- D• Revoke select on department from finance, cashier cascade;
2121. Privileges are granted over some specified parts of a database, such as a
- A• Schema
- B• Environment
- C• Relation Or view
- D• Query statement
2222. Prevention of access to the database by unauthorized users is referred to as:
- A• Integrity
- B• Productivity
- C• Security
- D• Reliability
2323. Database Authentication refers to:
- A• methods of restricting user access to system
- B• controlling access to portions of database
- C• all of the answers mentioned
- D• controlling the operation on the data
2424. A set of possible data values is called
- A• attribute
- B• degree
- C• domain
- D• tuple
2525. A functional dependency between two or more non-key attributes is called
- A• Partial transitive dependency
- B• Functional dependency
- C• Transitive dependency
- D• Partial functional dependency
2626. refers to the correctness and completeness of the data in a database.
- A• Database security
- B• Data constraint
- C• Data integrity
- D• Data independence
2727. Which of the following creates a virtual relation for storing the query?
- A• Function
- B• Procedure
- C• View
- D• None of the mentioned
2828. Which of the following is the syntax for views where v is view name?
- A• Create view v as “query name”;
- B• Create “query expression” as view;
- C• Create view v as “query expression”;
- D• Create view “query expression”;
2929. Updating the value of the view
- A• Will not change the view definition
- B• Will not affect the relation from which it is defined
- C• Will affect the relation from which it is defined
- D• Cannot determine
3030. Create view faculty as: Select ID, name, dept name from instructor; Find the error in this query.
- A• Instructor
- B• Select
- C• None of the mentioned
- D• View …as
3131. Which of the following is a basic form of grant statement?
- A• Grant ‘privilege list’ on ‘user/role list’ to ‘relation name or view name’;
- B• Grant ‘privilege list’ to ‘user/role list’;
- C• Grant ‘privilege list’ on ‘relation name or view name’ to ‘user/role list’;
- D• Grant ‘privilege list’ on ‘relation name or view name’ on ‘user/role list’;
3232. Retrieve all data from the table OFFICE { id,room, name}
- A• Select *from office;
- B• Select from office;
- C• Select name from office;
- D• Select *form office;
3333. Retrieve office name from the table OFFICE {id, room, name}
- A• Select *from office;
- B• Select from office;
- C• Select name from office;
- D• Select *form office;
3434. Retrieve office id from the table OFFICE {id, room, name}
- A• Select *from office;
- B• Select id from office;
- C• Select name from office;
- D• Select id form office;
3535. Retrieve office id and room from the table OFFICE {id, room, name}
- A• Select *from office;
- B• Select id, room from office;
- C• Select room name from office;
- D• Select id form office;
3636. Retrieve quantity of offices in the office table - OFFICE {id, rom, name}
- A• Select avg (id) from office;
- B• Select count (id) from office;
- C• Select sum (id) from office;
- D• Select max (id) from office;
3737. Retrieve total number scholarship in the students table – STUDENTS {id, name, scholarship, registereddate, tutorid}
- A• Select avg (scholarship) from office;
- B• Select count (scholarship) from office;
- C• Select sum (scholarship) from office;
- D• Select max (scholarship) from office;
3838. Retrieve quantity of students in the students table – STUDENTS {id, name, scholarship, registereddate, tutorid}
- A• Select avg (id) from office;
- B• Select count (id) from office;
- C• Select sum (id) from office;
- D• Select max (id) from office;
3939. Sort students name by descending order - STUDENTS {id, name, scholarship, registereddate, tutorid}
- A• Select name from students order by desc;
- B• Select name from students group by desc;
- C• Select *from students order by desc;
- D• Select name form students order by desc;
4040. Find an average scholarship of students - STUDENTS {id, name, scholarship, registereddate, tutorid}
- A• Select avg (scholarship) from students;
- B• Select count (scholarship) from students;
- C• Select sum (scholarship) from students;
- D• Select max (scholarship) from students;
4141. Find maximum scholarship of students - STUDENTS {id, name, scholarship, registereddate, tutorid}
- A• Select avg (scholarship) from students;
- B• Select count (scholarship) from students;
- C• Select sum (scholarship) from students;
- D• Select max (scholarship) from students;
4242. Find minimum scholarship of students - STUDENTS {id, name, scholarship, registereddate, tutorid}
- A• Select avg (scholarship) from students;
- B• Select count (scholarship) from students;
- C• Select min (scholarship) from students;
- D• Select max (scholarship) from students;
4343. Retrieve offices’ name and tutors’, who work in CSSE department. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, OFFICEID (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• Select o.name, t.name from office o join tutor t on o.id=t.officeid where o.name = ‘CSSE’
- B• Select o.name, t.name from office o join tutor t on o.id=t.id where o.name = ‘CSSE’
- C• Select o.name, t.name from office o join tutor t on o.id=t.officeid where o.name = ‘csse’
- D• Select o.name, t.name from office o join tutor t on o.id=t.officeid where o.name ‘CSSE’
4444. Retrieve all offices’ name and tutors’, who work in departments. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• Select o.name, t.name from office o left join tutor t on o.id=t.officeid;
- B• Select o.name, t.name from office o left join tutor t on o.id=t.id ;
- C• Select o.name, t.name from office o right join tutor t on o.id=t.officeid;
- D• Select o.name, t.name from office o right join tutor t on o.id=t.id ;
4545. Retrieve students’ name, who have more than average scholarship. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select s.name from students s where s.scholarship
> (select avg (scholarship)from students); - B• select s.name from students s where s.scholarship
> (select scholarship from students); - C• select s.name from students s where s.scholarship
> avg (scholarship); - D• select s.name from students s where s.scholarship
< avg (scholarship);
- A• select s.name from students s where s.scholarship
4646. Retrieve students’ name, who registered in 10th of Jan 2016. Tables: STUDENTS {id (PK), name, scholarship, registereddate, tutorid }.
- A• select name from students where registereddate = '2016-01-10';
- B• select name from students where registereddate = '2016-10-10';
- C• select name from students where registereddate = 2016-10-10;
- D• select name from students where registereddate = '2016-01-01';
4747. Retrieve tutors’ name, who have more than experience others along with their students name . Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}. (same answers in base, fixed here)
- A• select t.name, s.name from tutor t join students s on t.id=s.tutorid where experience = (select max (experience) from tutor);
- B• select t.name, s.name, max(experience) from tutor t join students s on t.id=s.tutorid;
- C• select t.name, s.name, max(experience) from tutor t join students s on t.id=t.tutorid;
- D• select t.name, s.name from tutor t join students s on t.id=s.id where experience = (select max (experience) from tutor);
4848. Retrieve tutors’ name, who have less experience than others along with their students name. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name,
scholarship, registereddate, tutorid (FK references tutor (id))}.
(same answers in base, fixed here)- A• select t.name, s.name from tutor t join students s on t.id=s.tutorid where experience = (select min (experience) from tutor);
- B• select t.name, s.name, min(experience) from tutor t join students s on t.id=s.tutorid;
- C• select t.name, s.name, min(experience) from tutor t join students s on t.id=t.tutorid;
- D• select t.name, s.name from tutor t join students s on t.id=s.id where experience = (select min (experience) from tutor);
4949. Increase tutors experience and students’ scholarship twice. Retrieve experience and scholarship along with their names. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select t.name,t.experience*2, s.name, s.scholarship*2 from tutor t join students s on t.id=s.tutorid;
- B• select t.name,t.experience*2, s.name, s.scholarship*2 from tutor t join students s on t.id=s.id;
- C• select t.name,t.experience*2, s.name, s.scholarship*2 from tutor t join tutor s on t.id=s.tutorid;
- D• select t.name,t.experience*2, s.name, s.scholarship*2 from tutor t join tutor s on t.id=s.id;
5050. Retrieve office, tutor and students name, but tutors name should have y value. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select o.name, t.name, st.name from tutor t join office o on o.id=t.officeid join students st on t.id=st.tutorid where t.name like '%y%';
- B• select o.name, t.name, st.name from tutor t join office o o.id=t.officeid join students st on t.id=st.tutorid where t.name like '%y%';
- C• select o.name, t.name, st.name from tutor t join office o on o.id=t.officeid join students st t.id=st.tutorid where t.name like '%y%';
- D• select o.name, t.name, st.name from tutor t join office o on o.id=t.officeid join students st on t.id=st.id where t.name like '%y%';
5151. Retrieve office, tutor and students name, but tutors name should not have y value. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutored (FK references tutor (id))}.
- A• select o.name, t.name, st.name from tutor t join office o on o.id=t.officeid join students st on t.id=st.tutorid where t.name not like '%y%';
- B• select o.name, t.name, st.name from tutor t join office o o.id=t.officeid join students st on t.id=st.tutorid where t.name not like '%y%';
- C• select o.name, t.name, st.name from tutor t join office o on o.id=t.officeid join students st t.id=st.tutorid where t.name not like '%y%';
- D• select o.name, t.name, st.name from tutor t join office o on o.id=t.officeid join students st on t.id=st.id where t.name not like '%y%';
5252. Retrieve students name and scholarship along with their department name, who have scholarship between 4000 and 5000. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select s.name, s.scholarship, o.name from office o join tutor t on o.id=t.officeid join students s on t.id=s.tutorid where s.scholarship between 4000 and 5000;
- B• select s.name, s.scholarship, o.name from office o join tutor t on o.id=t.officeid join students s on t.id=s.tutorid where s.scholarship 4000 and 5000;
- C• select s.name, s.scholarship, o.name from tutor t join students s on t.id=s.tutorid where s.scholarship between 4000 and 5000;
- D• select s.name, s.scholarship, o.name from tutor t join students s on t.id=s.tutorid where s.scholarship >=4000
5353. Retrieve information about office and their tutors as well. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select *from office o join tutor t on o.id=t.officeid;
- B• select *from office o join tutor t in o.id=t.officeid;
- C• select *form office o join tutor t on o.id=t.officeid;
- D• select *from office o join tutor t on o.id=t.id;
5454. Retrieve office name and tutor name, which have maximum experienced tutors. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select o.name, t.name from office o join tutor t on o.id=t.officeid where t.experience = (select max (experience) from tutor);
- B• select o.name, t.name from office o join tutor t on o.id=t.officeid where t.experience = (select min (experience) from tutor);
- C• select o.name, t.name from office o join tutor t on o.id=t.officeid where t.experience = (select high (experience) from tutor);
- D• select o.name, t.name from office o join tutor t on o.id=t.officeid where t.experience = (select low (experience) from tutor);
5555. Retrieve all tutors and students names. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select t.name, s.name from tutor t full join students s on t.id=s.tutorid;
- B• select t.name, s.name from tutor t full join students s t.id=s.tutorid;
- C• select t.name, s.name from tutor t full join students s t.id=s.id;
- D• select t.name, s.name from tutor t full join students s on t.id=s.id;
5656. Retrieve tutors’ name and the number of students for each of them. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select count (s.name) as numberofstudents, t.name from tutor t join students s on t.id=s.tutoridgroup by t.name;
- B• select count (s.name) as numberofstudents, t.name from tutor t join students s on t.id=s.tutorid;
- C• select count (s.name) as numberofstudents, t.name from tutor t join students s on t.id=s.idgroup by t.name;
- D• select count (s.name) as numberofstudents, t.name from tutor t join students s on t.id=s.id;
5757. Retrieve office name and the number of students for each of them. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))}.
- A• select count (s.name) as numberofstudents, o.name from tutor t join students s on t.id=s.tutoridjoin office o on o.id=t.officeid group by o.name;
- B• select count (s.name) as numberofstudents, o.name from students s on join office o on o.id=s.id group by o.name;
- C• select count (s.name) as numberofstudents, o.name from tutor t join students s on t.id=s.tutoridjoin office o o.id=t.officeid group by o.name;
- D• select count (s.name) as numberofstudents, o.name from tutor t join students s on t.id=s.idjoin office o on o.id=t.id group by o.name;
5858. Retrieve all students’ name and scholarship, tutors name except students who have scholarship 3000$. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select s.name, t.name from students s join tutor t on s.tutorid=t.id where s.scholarship <> 3000;
- B• select s.name, t.name from students s join tutor t on s.tutorid=t.id where s.scholarship = 3000;
- C• select s.name, t.name from students s join tutor t on s.tutorid=t.id where s.scholarship < 3000;
- D• select s.name, t.name from students s join tutor t on s.tutorid=t.id where s.scholarship is 3000;
5959. How many types of anomalies exist?
- A3
- B2
- C1
- D4
6060. Which of the following anomaly does not exist?
- A• Creation anomaly
- B• Deletion anomaly
- C• Insertion anomaly
- D• Modification anomaly
6161. When an insertion anomaly occurs?
- A• we are prevented from inserting some data into a relation until other data can be supplied
- B• deletion leads to an unintended loss of data
- C• it is possible that not all data needs to be changed will always be changed
- D• it does not occur
6262. When a modification anomaly occurs?
- A• it is possible that not all data needs to be changed will always be changed
- B• we are prevented from inserting some data into a relation until other data can be supplied
- C• deletion leads to an unintended loss of data
- D• it does not occur
6363. When a deletion anomaly occurs?
- A• deletion leads to an unintended loss of data
- B• it is possible that not all data needs to be changed will always be changed
- C• we are prevented from inserting some data into a relation until other data can be supplied
- D• it does not occur
6464. Define inner join
- A• selects all rows from both tables as long as there is a match between the columns in both tables
- B• returns all rows from the left table (1), with the matching rows in the right table (2)
- C• returns all rows from the right table (2), with the matching rows in the right table (1)
- D• returns all rows from the left table (1) and from the right table (2)
6565. Define left join
- A• returns all rows from the left table (1), with the matching rows in the right table (2)
- B• selects all rows from both tables as long as there is a match between the columns in both tables
- C• returns all rows from the right table (2), with the matching rows in the right table (1)
- D• returns all rows from the left table (1) and from the right table (2)
6666. Define right join
- A• returns all rows from the right table (2), with the matching rows in the left table (1)
- B• returns all rows from the left table (1), with the matching rows in the right table (2)
- C• selects all rows from both tables as long as there is a match between the columns in both tables
- D• returns all rows from the left table (1) and from the right table (2)
6767. Define full join
- A• returns all rows from the left table (1) and from the right table (2)
- B• returns all rows from the right table (2), with the matching rows in the right table (1)
- C• returns all rows from the left table (1), with the matching rows in the right table (2)
- D• selects all rows from both tables as long as there is a match between the columns in both tables
6868. Define a union
- A• combines the result set of two or more select statements
- B• returns all rows from the left table (1) and from the right table (2)
- C• returns all rows from the right table (2), with the matching rows in the right table (1)
- D• returns all rows from the left table (1), with the matching rows in the right table (2)
6969. INNER JOIN and JOIN are the same
- ARichtig
- BFalsch
7070. Define self join
- A• returns all rows from the table that references to yourself
- B• returns all rows from the right table (2), with the matching rows in the right table (1)
- C• selects all rows from both tables as long as there is a match between the columns in both tables
- D• returns all rows from the left table (1) and from the right table (2)
7171. How many types of functional dependencies exist
- A3
- B2
- C1
- D0
7272. Which of the following does not to the functional dependency
- A• equational
- B• full
- C• transitive
- D• partial
7373. Which of the following represent a full dependency?
- A• it exists in relation if there is no attribute A that can be removed from X and the dependency still holds
- B• if there exists an attribute A that is part of X that can be removed from X and the dependency still holds
- C• x->y dependency in relation R and x, y , z are columns in R. X->Y and Y>Z in R. Final: X->Y
- D• all above mentioned
7474. Which of the following represent a partial dependency?
- A• if there exists an attribute A that is part of X that can be removed from X and the dependency still holds
- B• it exists in relation if there is no attribute A that can be removed from X and the dependency still holds
- C• x->y dependency in relation R and x, y , z are columns in R. X->Y and Y>Z in R. Final: X->Y
- D• all above mentioned
7575. Which of the following represent a transitive dependency?
- A• x->y dependency in relation R and x, y , z are columns in R. X->Y and Y->Z in R. Final: X->Y
- B• if there exists an attribute A that is part of X that can be removed from X and the dependency still holds
- C• it exists in relation if there is no attribute A that can be removed from X and the dependency still holds
- D• all above mentioned
7676. When was first normalization developed?
- A• 1970
- B• 1972
- C• 1973
- D• 1974
7777. When was second normalization developed?
- A• 1971
- B• 1972
- C• 1973
- D• 1974
7878. When was **third** normalization developed?
- A• 1974
- B• 1972
- C• 1973
- D• 1971
7979. Who is an inventor of relational model?
- A• Edgar F.Codd
- B• Raymond Boyce
- C• Marine Jone
- D• John Salamondor
8080. Which of the following refers to the requirement of 1NF
- A• Each cell should be single valued
- B• All attributes (non-key columns) dependent on the key
- C• All fields (columns) can be determined only by the key in the table and no other column
- D• All above mentioned
8181. Which of the following refers to the requirement of 1NF
- A• Each cell should be single valued
- B• Entries in a column are same type
- C• Rows uniquely identified
- D• All above mentioned
8282. Which of the following refers to the requirement of 2NF
- A• All attributes (non-key columns) dependent on the key
- B• Each cell should be single valued
- C• All fields (columns) can be determined only by the key in the table and no other column
- D• All above mentioned
8383. Which of the following refers to the requirement of 2NF
- A• All fields (columns) can be determined only by the key in the table and no other column
- B• All attributes (non-key columns) dependent on the key
- C• Each cell should be single valued
- D• All above mentioned
8484. Define avg function
- A• Returns average value
- B• Returns total value
- C• Returns the first value
- D• Converts to lowercase
8585. Which function is used to retrieve quantity of rows
- A• count
- B• sum
- C• avg
- D• max
8686. Retrieve avg scholarship of students. Tables: office {id (PK), locations, name}, tutor {id (PK), name, officeid (FK references office (id)), experience}, students {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select avg (scholarship) from students;
- B• select aveg (scholarship) from students
- C• select avr (scholarship) from students;
- D• select avgr (scholarship) from students;
8787. Retrieve students’, scholarship and teacher's’ name, who have more than average scholarship. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select s.name, s.scholarship, t.name from students s, tutor t where t.id=s.tutorid and s.scholarship> (select avg(scholarship) from students)
- B• select s.name, s.scholarship, t.name from students s, tutor t where t.id=s.tutorid and s.scholarship> avg(scholarship)
- C• select s.name, s.scholarship, t.name from students s, tutor t where s.scholarship> (select avg(scholarship) from students)
- D• select s.name, avg(s.scholarship), t.name from students s, tutor t
8888. Retrieve students’, scholarship and teacher's’ name, who have more than average scholarship AND increase those students twice. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select s.name, s.scholarship*2, t.name from students s, tutor t where t.id=s.tutorid and s.scholarship> (select avg(scholarship) from students)
- B• select s.name, s.scholarship*2, t.name from students s, tutor t where t.id=s.tutorid and s.scholarship> avg(scholarship)
- C• select s.name, s.scholarship*2, t.name from students s, tutor t where s.scholarship> (select avg(scholarship) from students)
- D• select s.name, avg(s.scholarship)*2, t.name from students s, tutor t
8989. Retrieve students and mentors name, but mentors registration date should be before students registration date. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select s.name, m.name from students s join students m on s.tutorid=m.tutorid where s.registereddate<m.registereddate;
- B• select s.name, m.name from students s join students m on s.tutorid=m.tutorid where s.registereddate>m.registereddate;
- C• select s.name, m.name from students s join students m on s.tutorid=m.tutorid;
- D• select s.name, m.name from students s join students m on s.registereddate=m.registereddate;
9090. Retrieve the highest experience from tutor. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select max (experience) from tutor;
- B• select min (experience) from tutor;
- C• select max (t.experience) from tutor t group by t.name;
- D• select min (t.experience) from tutor t group by t.name;
9191. Retrieve the lowest experience from tutor. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select min (experience) from tutor;
- B• select max (experience) from tutor;
- C• select max (t.experience) from tutor t group by t.name;
- D• select min (t.experience) from tutor t group by t.name;
9292. Retrieve book name, number of books, price and publisher, for those books which have more than 20 copies. Tables : BOOK {bookid, title, publisher_name, price}. BOOKCOPIES {bookid, libraryid,noOfCopies [references Book (bookid)]}
- A• select count (b.bookid),b.title, b.price, b.publisher_name from book b join book_copies bc on b.bookid=bc.bookid where bc.no_of_copies>20 group by b.title, b.price, b.publisher_name;
- B• select count (b.bookid),b.title, b.price, b.publisher_name from book b join book_copies bc on b.bookid=bc.bookid where bc.no_of_copies>20;
- C• select count (b.bookid),b.title, b.price, b.publisher_name from book b join book bc on b.bookid=bc.bookid where bc.no_of_copies>20 group by b.title, b.price, b.publisher_name;
- D• select b.bookid,b.title, b.price, b.publisher_name from book b join book_copies bc on b.bookid=bc.bookid where bc.no_of_copies>20 group by b.title, b.price, b.publisher_name;
9393. Retrieve card number, book name, borrower name, who have borrowed in 12 July, bookid (references Book (bookid)), libraryid (references Library (libraryid)), cardno 2013. Tables: BOOK {bookid, title, publisher_name, price}. BOOKLOANS {bookloans, cardno(references Borrower (cardno)),bookid (references Book (bookid)) dateout, duedate}. BORROWER {cardno, c_name, b_address, phoneno}
- A• select bl.cardno, b.title, br.c_name from book b join
bookloans bl on bl.bookid=b.bookid join borrower br on br.cardno=bl.cardno where bl.dateout='12- 07-2013' - B• select bl.cardno, b.title, br.c_name from book b join bookloans bl on bl.bookid=b.bookid join borrower br on br.cardno=bl.cardno where bl.duedate='12-
07-2013' - C• select bl.cardno, b.title, br.c_name from book b join bookloans bl on bl.bookid=b.bookid where bl.dateout='12-07-2013'
- D• select bl.cardno, b.title, br.c_name from book b join borrower br on br.cardno=bl.cardno where bl.dateout='12-07-2013'
- A• select bl.cardno, b.title, br.c_name from book b join
9494. Retrieve max price for Fariza's publication. BOOK {bookid, title, publisher_name, price}.BOOK_AUTHORS {author_name, bookid (references Book (bookid))}
- A• select max (b.price)from book b join book_authors ba on b.bookid=ba.bookid where ba.author_name = 'Fariza';
- B• select max (b.price)from book b join book_authors ba on b.bookid=ba.bookid where ba.author_name = Fariza;
- C• select max (b.price)from book b join book_authors ba b.bookid=ba.bookid where ba.author_name = 'Fariza';
- D• select max (b.price)from book b join book_authors ba on b.bookid=ba.bookid;
9595. Retrieve book name, total number of book copies. BOOK {bookid, title, publisher_name, price}. BOOKCOPIES {bookid, libraryid,noOfCopies [references Book (bookid)]}
- A• select b.title, sum (no_of_copies) from book b join book_copies bc on b.bookid=bc.bookid group by b.title;
- B• select b.title, sum (no_of_copies) from book b join book_copies bc b.bookid=bc.bookid group by b.title;
- C• select b.title, count(no_of_copies) from book b join book_copies bc on b.bookid=bc.bookid group by b.title;
- D• select b.title, count(no_of_copies) from book b join book_copies bc b.bookid=bc.bookid group by b.title;
9696. Retrieve book title and total number of book copies, which has id 1. BOOK {bookid, title, publisher_name, price}. BOOKCOPIES {bookid, libraryid,noOfCopies [references Book (bookid)]}
- A• select b.title, sum (no_of_copies) from book b join book_copies bc on b.bookid=bc.bookid where b.bookid=1 group by b.title;
- B• select b.title, sum (no_of_copies) from book b join book_copies bc on b.bookid=bc.bookid where b.bookid=1;
- C• select b.title, count (no_of_copies) from book b join book_copies bc on b.bookid=bc.bookid where b.bookid=1 group by b.title;
- D• select b.title, count (no_of_copies) from book b join book_copies bc on b.bookid=bc.bookid where b.bookid=1;
9797. Retrieve borrower name and number of books that each borrower has. BOOKLOANS
{bookloans, bookid (references Book (bookid)), libraryid (references Library (libraryid)), cardno (references Borrower (cardno)), dateout, duedate}. BORROWER {cardno, c_name, b_address, phoneno}- A• select br.c_name, count(bl.bookid) from borrower br join bookloans bl on br.cardno = bl.cardno group by br.c_name;
- B• select br.c_name, count(bl.bookid) from borrower br join bookloans bl on br.cardno = bl.cardno;
- C• select br.c_name, sum(bl.bookid) from borrower br join bookloans bl on br.cardno = bl.cardno group by br.c_name;
- D• select br.c_name, sum(bl.bookid) from borrower br join bookloans bl on br.cardno = bl.cardno;
9898. Retrieve books name and prices. Increase price twice more for books, which have more than 20 copies;BOOK {bookid, title, publisher_name, price}. BOOKCOPIES {bookid, libraryid,noOfCopies [references Book (bookid)]}
- A• select b.title, b.price, b.price *2 as increasedprice from book b join book_copies bc on bc.bookid=b.bookid where bc.no_of_copies > 20;
- B• select b.title, b.price book b join book_copies bc on bc.bookid=b.bookid where bc.no_of_copies > 20;
- C• impossible to solve
- D• select b.title, b.price, b.price *2 as increasedprice from book b join book_copies bc on bc.bookid=b.bookid;
9999. Retrieve library name, book name, number of copies, which have more than 25 copies. BOOK {bookid, title, publisher_name, price}. BOOKCOPIES {bookid, libraryid,noOfCopies [references Book (bookid)]}. LIBRARY (libraryid)), cardno (references Borrower (cardno)), dateout, duedate}.
- A• select l.libraryname, b.title, bc.no_of_copies from book b join book_copies bc on b.bookid=bc.bookid join library l on l.libraryid = bc.libraryid where bc.no_of_copies>25;
- B• select l.libraryname, b.title, bc.no_of_copies from book b join book_copies bc on b.bookid=bc.bookid where bc.no_of_copies>25;
- C• select l.libraryname, b.title, bc.no_of_copies from book join library l on l.libraryid = bc.libraryid where bc.no_of_copies>25;
- D• select l.libraryname, b.title, bc.no_of_copies from book b join book_copies bc on b.bookid=bc.bookid join library l l.libraryid = bc.libraryid where bc.no_of_copies>25;
100100. Retrieve the number of departments in the department table. Tables: DEPARTMENT {id, name}. EMPLOYEE {id, name, salary, dep_id (references Department (id))}
- A• select count(id) from department
- B• select sum (id) from department;
- C• select coun(id) from department
- D• select id from department
101101. Retrieve total salaries payable to employee. Tables: DEPARTMENT {id, name}. EMPLOYEE {id, name, salary, dep_id (references Department (id))}
- A• select sum (salary) from employee;
- B• select count(salary) from employee;
- C• select sum (id) from employee;
- D• select max (salary) from employee;
102102. Retrieve office name and tutor name, who have experience equal or more than five years. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select o.name, t.name from office o join tutor t on o.id=t.officeid where t.experience >=5;
- B• select o.name, t.name from office o join tutor t on o.id=t.officeid where t.experience >5;
- C• select o.name, t.name from office o join tutor t o.id=t.officeid where t.experience >=5;
- D• select o.name, t.name from office join tutor on o.id=t.officeid where t.experience >=5;
103103. Retrieve tutor name and their office locations, who refer to CSSE and Management. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select t.name, o.locations from office o join tutor t on o.id=t.officeid where o.name in ('CSSE', 'Management');
- B• select t.name, o.locations from office o join tutor t on o.id=t.officeid where o.name in ('CSSE' or 'Management');
- C• select t.name, o.locations from office o join tutor t o.id=t.officeid where o.name in ('CSSE', 'Management');
- D• select t.name, o.locations from office o join tutor t on o.id=t.officeid where o.name in ('CSSE') or ('Management');
104104. Retrieve student's name, which starts from A. Tables: OFFICE {id (PK), LOCATIONS, name}, tutor {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select name from students where name like 'A_%';
- B• select name from students where name like 'A';
- C• select name from students where name like 'a%';
- D• select name from students where name like '%A%'
105105. Retrieve all students name with the department name, but excluding department CSSE. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select s.name, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid where o.name <> 'CSSE';
- B• select s.name, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid;
- C• select s.name, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid where o.name = 'CSSE';
- D• select s.name, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name, s.name;
106106. Which of the following query is incorrect for retrieving all students name with the department name, but excluding department CSSE. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select s.name, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid where o.name <= 'CSSE';
- B• select s.name, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid where o.name <> 'CSSE';
- C• select s.name, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid where o.name not like 'CSSE';
- D• select s.name, o.name from students s join tutor t
on t.id=s.tutorid join office o on o.id=t.officeid where o.name not in ('CSSE');
107107. Retrieve students name, scholarship and their office name, who have scholarship ranging from 3200 to 4500.Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select s.name, s.scholarship, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid where s.scholarship between 3200 and 4500;
- B• select s.name, s.scholarship, o.name from students s join tutor t on t.id=s.tutorid where s.scholarship between 3200 and 4500;
- C• select s.name, s.scholarship, o.name from students join office o on o.id=t.officeid where s.scholarship between 3200 and 4500;
- D• select s.name, s.scholarship, o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid where s.scholarship 3200 and 4500;
108108. What kind symbol is used to find one character in wildcards?
- A• _
- B• ?
- C• $
- D• in
109109. Find an average scholarship of students. Tables: STUDENTS {id (PK), name, scholarship, registereddate, tutorid }
- A• select avg (scholarship) from students ;
- B• select averg (scholarship) from students ;
- C• select av (scholarship) from students ;
- D• select avrg (scholarship) from students ;
110110. Retrieve average scholarship of students for each department. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select avg (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- B• select avg (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid ;
- C• select avg (scholarship), o.name from students s join tutor t on t.id=s.tutorid group by o.name;
- D• select avg (scholarship), o.name from students s d join office o on o.id=t.officeid group by o.name;
111111. Retrieve student number in each department. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select count (s.id), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- B• select sum (s.id), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- C• select o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- D• select count (s.id), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid;
112112. Retrieve total amount of scholarship of each department. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select sum (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- B• select count (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- C• select sum (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid;
- D• select count (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid;
113113. Retrieve student number in each department. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select count (s.id), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- B• select sum (s.id), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- C• select o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- D• select count (s.id), o.name from students s join tutor t
- E• on t.id=s.tutorid join office o on o.id=t.officeid;
114114. Retrieve total amount of scholarship of each department. Tables: OFFICE {id (PK), locations, name}, TUTOR {id (PK), name, officeid (FK references office (id)), experience}, STUDENTS {id (PK), name, scholarship, registereddate, tutorid (FK references tutor (id))
- A• select sum (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- B• select count (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid group by o.name;
- C• select sum (scholarship), o.name from students s join tutor t on t.id=s.tutorid join office o on o.id=t.officeid;
- D• select count (scholarship), o.name from students s
join tutor t on t.id=s.tutorid join office o on o.id=t.officeid;
115115. SQL stands for
- A• Sequence Question Language
- B• Structured Query Language
- C• Structured Querty Language
- D• Selection Query Language
116What is it?

- A• Relation
- B• Tuples
- C• Attributes
- D• Relationships
117117. What is it

- A• Relation
- B• Tuples
- C• Attributes
- D• Relationships
118118. What is it

- A• Relation
- B• Tuples
- C• Attributes
- D• Relationships
119119. You can add a row using SQL in a database with which of the following
- A• ADD
- B• CREATE
- C• INSERT
- D• UPDATE
120120. The command to remove rows from a table “Customer”
- A• Remove from Customer
- B• Delete from Customer
- C• Drop from Customer
- D• Update row from Customer
121121. Choose the correct relational algebra operation

- A• Union
- B• Difference
- C• Intersection
- D• Product
122122. Choose the correct relational algebra operation

- A• Union
- B• Difference
- C• Intersection
- D• Product
123123. Choose the correct relational algebra operation

- A• Union
- B• Difference
- C• Intersection
- D• Product
124124. Choose the correct relational algebra operation

- A• Union
- B• Difference
- C• Intersection
- D• Product
125125. The SQL WHERE clause
- A• Condition that limits the column data that are returned
- B• Condition that limits the row data are returned
- C• Clause that returns all rows
- D• Clause that returns nothing
126126. The command to eliminate a table from a database
- A• Drop
- B• Delete
- C• Remove
- D• Update
127127. Which of the following is correct order of keywords for SQL Select statement?
- A• SELECT, FROM, WHERE
- B• WHERE, FROM, SELECT
- C• FROM, WHERE, SELECT
- D• SELECT, WHERE, FROM
128128. Are given table union compatible ?

- A• Yes
- B• No
- C• I do not know
- D• May be
129129. SQL data definition commands make up a(n)
- A• DDC
- B• DML
- C• DDL
- D• DDD
130130. In a relation, the columns are also called attributes
- A• True
- B• False
- C• May be
- D• I do not know
131131. Find the SQL statement that is equal to: SELECT NAME FROM CUSTOMER WHERE STATE = 'VA';
- A• SELECT NAME IN CUSTOMER WHERE STATE IN 'VA';
- B• SELECT NAME IN CUSTOMER WHERE STATE = 'VA';
- C• SELECT NAME FROM CUSTOMER WHERE STATE IN 'VA';
- D• SELECT NAME IN CUSTOMER WHERE STATE = 'V';
132132. In E\R diagrams, we will represent Entities as
- A• Boxes with rounded corners
- B• Links between two entities
- C• Ovals
- D• Diamond box
133133. In E\R diagrams, we will represent Relationships as
- A• Boxes with rounded corners
- B• Links between two entities
- C• Ovals
- D• Diamond box
134134. In E\R diagrams, we will represent Attributes as
- A• Boxes with rounded corners
- B• Links between two entities
- C• Ovals
- D• Diamond box
135135. Many to many relationships are difficult to represent in database, so we need to
- A• Split many to many relationship into two one to many relationships
- B• Split one to many relationship into two one to many relationships
- C• Split many to many relationship into one to many relationships
- D• Split many to many relationship into three one to many relationships
136136. The result of a SQL SELECT statement is a(n)
- A• Report
- B• Table
- C• Form
- D• File
137137. Which of the following are the five built-in functions provided by SQL?
- A• COUNT, SUM, AVG, MAX, MULT
- B• SUM, AVG, MIN, MAX, NAME
- C• SUM, AVG, MULT, DIV, MIN
- D• COUNT, SUM, AVG, MAX, MIN
138138. In a relation, the order of the rows matters
- A• True
- B• False
- C• I do not know
- D• May be
139139. Given the functional dependency R → (S,T) , then it is also true that R → S
- A• True
- B• False
- C• I do not know
- D• May be
140140. Given the functional dependency R → (S,T) , then it is also true that R → T
- A• True
- B• False
- C• I do not know
- D• May be
141141. SQL can be used to
- A• create database structures only
- B• query database data only
- C• modify database data only
- D• All of the these can be done by SQL
142142. The SQL statement that queries or reads data from a table is
- A• READ
- B• QUERY
- C• SELECT
- D• NONE
143143. A subquery in an SQL SELECT statement
- A• can only be used with two tables
- B• has a distinct form that cannot be duplicated by a join
- C• can always be duplicated by a join
- D• cannot have its results sorted using ORDER BY
144144. The SQL keyword BETWEEN is used
- A• for ranges
- B• as a wildcard
- C• to limit the columns displayed
- D• None of the above
145145. Sometimes you want to change the structure of an existing table, what are your options?
- A• Change table
- B• Drop Table
- C• Alter Table
- D• Create Table
146146. how to Add a new column into existing table?
- A• ALTER TABLE Student MODIFY COLUMN sDegree CHAR(64) NOT NULL
- B• ALTER TABLE Student ADD COLUMN sDegree VARCHAR(64) NOT NULL
- C• ALTER TABLE S ADD COLUMN s VACHAR(64) NOT NULL
- D• ALTER TABLE Student DROP COLUMN sDegree VARCHAR(64) NOT NULL
147147. how to rename a column in existing table?
- A• ALTER TABLE Student MODIFY COLUMN sDegree CHAR(64) NOT NULL
- B• ALTER TABLE Student ADD COLUMN sDegree VARCHAR(64) NOT NULL
- C• ALTER TABLE Student RENAME COLUMN s to SS VACHAR(64) NOT NULL
- D• ALTER TABLE Student DROP COLUMN sDegree VARCHAR(64) NOT NULL
148148. how to change the row(s) in a table
- A• insert
- B• update
- C• change
- D• delete
149149. how to remove the row(s) from a table
- A• insert
- B• update
- C• change
- D• delete
150150. Which of the following is not correct ?

- A• INSERT INTO Employee(ID, Name, Salary) VALUES(2,‘Mary’,26);
- B• INSERT INTO Employee (Name,ID) VALUES (‘Mary’,2);
- C• INSERT INTO Employee VALUES (2, ‘Mary’,26000);
- D• INSERT INTO Employe VALUES(26, ‘Mary’,26);
151151. Please increase salary for 10% ?

- A• UPDATE Employee SET Salary = Salary*0.5
- B• UPDATE Employee SET Salary = Salary * 0.1
- C• UPDATE Employee SET Salary = Salary * 1.1
- D• UPDATE Employee Update Salary = Salary*0.1
152152. Please remove staff, who earns more than 22000 ?

- A• DELETE FROM Employee WHERE Salary >=22000;
- B• DELETE FROM Employe WHERE Salary => 22000;
- C• REMOVE FROM Employee WHERE Salary >22000;
- D• DELETE FROM Employee WHERE Salary = 22000;
153153. πs Name,sAddress (Student) is equal to?
- A• SELECT Sname FROM Students
- B• SELECT Sname, SAddress FORM Students
- C• SELECT Sname and SAddress FROM Students
- D• SELECT Sname, SAddress FROM Student
154154. SQL query to find a list of the ID numbers and Marks for students
who have passed IAI
- A• Select ID, Mark from Grade Where code = 'IAI' and Mark > 50;
- B• Select ID, Mark from Grade Where code = 'AIA' and Mark > 50;
- C• Select ID, Mark, Code from Grade Where code = 'IAI';
- D• Select ID, Mark from Grade Where code = 'IAI' and Mark >=50;
155155. Find students who studying any Programming module

- A• Select First,Last from Student,Grade Where Code='PR1'OR'PR2'
- B• Select First,Last from Student Natural Join Grade Where Code like'PR%'
- C• Select First Last from Student Natural Join Grade Where Code like'PR%'
- D• Select First from Student Natural Join Grade Where Code = 'PR%'
156156. A SELECT statement can be nested inside another query to form a
- A• Subselect
- B• Subresults
- C• Subquery
- D• Query in query
157157. SQL uses privileges to control access to tables and other database objects, so which is NOT?
- A• Select privilege
- B• Update privilege
- C• Insert privilege
- D• Drop privilege
158158. How to use privileges in SQL?
- A• ON<objects> TO<users> GRANT<privileges>
- B• GRANT<privileges> ON<objects> TO<users>
- C• GRANT<privileges> TO<users> ON<objects>
- D• GRANT<tables> ON<objects> TO<users>
159159. If Admin’ grants ALL privileges to ‘Manager’, and SELECT to ‘Finance’ with grant option, So..

- A• ‘Manager’ grants ALL to ‘Personnel’
- B• ‘Manager’ grants SELECT to ‘Personnel’
- C• ‘Finance’ grants SELECT to ‘Manager’
- D• ‘Finance’ grants ALL to ‘Manager’
160160. If Admin’ grants ALL privileges to ‘Manager’, and SELECT to ‘Finance’ with grant option, So..

- A• ‘Finance’ grants SELECT to ‘Personnel’
- B• ‘Manager’ grants SELECT to ‘Personnel’
- C• ‘Finance’ grants SELECT to ‘Manager’
- D• ‘Finance’ grants ALL to ‘Manager’
161161. If ‘Manager’ revokes ALL from ‘Personnel’

- A• ‘Personnel’ still has ALL privileges from ‘Finance’
- B• ‘Finance’ still has SELECT privileges from ‘Personnel’
- C• ‘Personnel’ still has SELECT privileges from ‘Finance’
- D• ‘Admin’ still has ALL privileges from ‘Finance’
162162. If ‘Finance revokes SELECT from ‘Personnel’

- A• ‘Personnel’ still has ALL privileges from ‘Finance’
- B• ‘Finance’ still has SELECT privileges from ‘Personnel’
- C• ‘Personnel’ still has ALL privileges from ‘Manager’
- D• ‘Admin’ still has ALL privileges from ‘Finance’
163163. If ‘Admin’ revokes Select from ‘Finance’

- A• ‘Personnel’ still has ALL privileges from ‘Finance’
- B• ‘Finance’ still has SELECT privileges from ‘Personnel’
- C• ‘Personnel’ still has ALL privileges from ‘Manager’
- D• ‘Admin’ still has ALL privileges from ‘Finance’
164164. If ‘Admin’ revokes ALL from ‘Manager’

- A• ‘Personnel’ still has ALL privileges from ‘Finance’
- B• ‘Finance’ still has SELECT privileges from ‘Personnel’
- C• ‘Finance still has SELECT privileges from ‘Admin’
- D• ‘Admin’ still has ALL privileges from ‘Finance’
165165. If Admin’ grants ALL privileges to ‘Manager’, and SELECT to ‘Finance’ with grant option, So..

- A• ‘Manager’ grants ALL to ‘Personnel’
- B• ‘Manager’ grants SELECT to ‘Personnel’
- C• ‘Finance’ grants SELECT to ‘Manager’
- D• ‘Finance’ grants ALL to ‘Manager’
166166. To convert any relation into , split any nonatomic values
- A• First normal form
- B• Second normal form
- C• Third normal form
- D• Fourth normal form
167167. A functional dependency (FD) is a
- A• link between three sets of attributes in a relation
- B• link between all sets of attributes in a relation
- C• link between four sets of attributes in a relation
- D• link between two sets of attributes in a relation
168168. which if the following does not refer to redundancy problems?
- A• INSERT anomalies
- B• CREATE anomalies
- C• UPDATE anomalies
- D• DELETE anomalies
169169. To convert any relation into , remove transitive dependency
- A• First normal form
- B• Second normal form
- C• Third normal form
- D• Fourth normal form
170170. To convert any relation into , split any nonatomic values
- A• First normal form
- B• Second normal form
- C• Third normal form
- D• Fourth normal form
171171. A functional dependency (FD) is a
- A• link between three sets of attributes in a relation
- B• link between all sets of attributes in a relation
- C• link between four sets of attributes in a relation
- D• link between two sets of attributes in a relation
172172. which if the following does not refer to redundancy problems?
- A• INSERT anomalies
- B• CREATE anomalies
- C• UPDATE anomalies
- D• DELETE anomalies
173173. To convert any relation into , remove transitive dependency
- A• First normal form
- B• Second normal form
- C• Third normal form
- D• Fourth normal form
174174. SQL stands for
- A• Sequence Question Language
- B• Structured Query Language
- C• Structured Querty Language
- D• Selection Query Language
175175. What is it ?

- A• Relation
- B• Tuples
- C• Attributes
- D• Relationships
176176. What is it ?

- A• Relation
- B• Tuples
- C• Attributes
- D• Relationships
177177. What is it ?

- A• Relation
- B• Tuples
- C• Attributes
- D• Relationships
178178. which if the following does not refer to redundancy problems?
- A• INSERT anomalies
- B• CREATE anomalies
- C• UPDATE anomalies
- D• DELETE anomalies
179179. To convert any relation into ____, remove transitive dependency
- A• First normal form
- B• Second normal form
- C• Third normal form
- D• Fourth normal form
180180. To convert any relation into ____ , split any nonatomic values
- A• First normal form
- B• Second normal form
- C• Third normal form
Informationen
- Beschreibung
- Quiz am DatabaseInIS, erstellt von Howard Gakes am 12/04/2021.
- Autor
- Howard Gakes
- Sprache
- English
- Aufrufe
- 17
- Bewertung
- Noch keine Bewertungen Bewerte dieses Quiz