This quiz works best with JavaScript enabled. Home > Class 12 > Class 12 Computer Science Chapter 4 Structured Query Language (Sql) – Quiz 2 🏠 Homepage 📘 Download PDF Books 📕 Premium PDF Books Class 12 Computer Science Chapter 4 Structured Query Language (Sql) Quiz 2 (25 MCQs) Quiz Instructions Select an option to see the correct answer instantly. 1. State True or False:1. SELECT statement is used to extract records from one or more tables A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: A) True. 2. What does * mean when writing code? A) Select all columns. B) Select all rows. C) Select all genres. D) Select jaskfjfjfjsfjiosjisjfjsfjsfjkjsk. Show Answer Correct Answer: A) Select all columns. 3. Which type of language is SQL? A) Declarative. B) Procedural. C) Object-oriented. D) Functional. Show Answer Correct Answer: A) Declarative. 4. What could be the correct datatype for 'H.NO. 234, SEC-14' data A) Date. B) Int. C) Varchar. D) Decimal. Show Answer Correct Answer: C) Varchar. 5. State the use of WHERE clause. A) In SELECT statement specifies the condition, which restricts the rows returned by the query. B) In SELECT statement indicates the table(s) from which data is to be retrieved. C) It is used to extract records from one or more tables. D) None of the above. Show Answer Correct Answer: A) In SELECT statement specifies the condition, which restricts the rows returned by the query. 6. Pernyataan SQL manakah yang digunakan untuk mengekstrak data daripada pangkalan data? A) EXTRACT. B) SELECT. C) OPEN. D) GET. Show Answer Correct Answer: B) SELECT. 7. Choose SQL command to display the name of cake that end with word cheese. A) SELECT cakeNameFROM CAKEWHERE cakeName LIKE "%cheese";. B) SELECT cakeNameFROM CAKEWHERE cakeName LIKE "cheese%";. C) SELECT cakeNameFROM CAKEWHERE cakeName LIKE "%cheese%";. D) SELECT cakeNameFROM CAKEWHERE cakeName LIKE "cheese";. Show Answer Correct Answer: B) SELECT cakeNameFROM CAKEWHERE cakeName LIKE "cheese%";. 8. SELECT *FROM BarangORDER BY NamaBarang DESCPernyataan diatas bertujuan untuk A) Menyenaraikan SEMUA maklumat dalam jadual Barang secara menurun. B) Menyenaraikan BEBERAPA maklumat dalam jadual Barang secara menaik. C) Menyenaraikan BEBERAPA maklumat dalam jadual Barang secara menurun. D) Menyenaraikan SEMUA maklumat dalam jadual Barang secara menaik. Show Answer Correct Answer: A) Menyenaraikan SEMUA maklumat dalam jadual Barang secara menurun. 9. In a database, what is the role of a primary key? A) To link tables together. B) To uniquely identify each record in a table. C) To store a single piece of data for all records. D) To provide a user interface for data entry. Show Answer Correct Answer: B) To uniquely identify each record in a table. 10. TRUE OR FALSE:when adding data to all fields in a table, you still have to specify the field names A) TRUE. B) FALSE. C) All the above. D) None of the above. Show Answer Correct Answer: B) FALSE. 11. Choose the CORRECT query for using comparison operators in SQL. A) SELECT eName, ePositionFROM employeeInfoWHERE age>40 AND <60;. B) SELECT eName, ePositionFROM employeeInfoWHERE age>40 AND age<60;. C) SELECT eName, ePositionFROM employeeInfoWHERE age>40 AND WHERE age<60;. D) SELECT eName, ePositionFROM employeeInfoWHERE >40 AND <60 age;. Show Answer Correct Answer: B) SELECT eName, ePositionFROM employeeInfoWHERE age>40 AND age<60;. 12. Which SQL statement is used to update existing records in a table? A) CHANGE. B) MODIFY. C) UPDATE. D) None of the above. Show Answer Correct Answer: C) UPDATE. 13. Which of the following SQL clauses is used to DELETE tuples from a database table? A) DELETE. B) REMOVE. C) DROP. D) CLEAR. Show Answer Correct Answer: A) DELETE. 14. What is the default sorting order of the ORDER BY clause in SQL? A) Ascending. B) Descending. C) All the above. D) None of the above. Show Answer Correct Answer: A) Ascending. 15. Arthur is working on a database for his school project and wants to retrieve specific data from a table. Which SQL statement should he use? A) SELECT. B) INSERT. C) DELETE. D) UPDATE. Show Answer Correct Answer: A) SELECT. 16. Apakah maksud SQL? A) Structured Question Language. B) Sorted Query Language. C) Structured Query Language. D) Strong Question Language. Show Answer Correct Answer: C) Structured Query Language. 17. What does the SQL command 'DROP TABLE' do? A) Deletes existing tables. B) Modifies the structure of a table. C) Inserts new records into a table. D) Selects specific data from a table. Show Answer Correct Answer: A) Deletes existing tables. 18. Which of the following is the label we give a column that the "outside world" uses to look up a particular row? A) Logical key. B) Remote key. C) Foreign key. D) Local key. E) Primary key. Show Answer Correct Answer: A) Logical key. 19. Which function is used to calculate the summary values? A) Aggregate. B) F5. C) SUM. D) AVERAGE. Show Answer Correct Answer: A) Aggregate. 20. .... have a special meaning in SQL. A) Variables. B) Commands. C) Arguments. D) Keyword. Show Answer Correct Answer: D) Keyword. 21. SQL query to find all the cities whose humidity is 95. A) SELECT city WHERE humidity = 95. B) SELECT city FROM weather WHERE humidity = 95. C) SELECT humidity = 89 FROM weather. D) SELECT city FROM weather. Show Answer Correct Answer: B) SELECT city FROM weather WHERE humidity = 95. 22. The ..... consist of SQL statements used to define the database structure or schema. A) DDL. B) DML. C) DCL. D) TCL. Show Answer Correct Answer: A) DDL. 23. Images, PDF, movies cannot be stored in a database. A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: B) False. 24. Apakah penyataan SQL untuk mengemas kini nombor telefon '012345678' hanya untuk attribut DesignerID, "SMI01" dalam jadual "Designer" ? A) UPDATE Designer SET PhoneNo = '012345678'. B) UPDATE PhoneNo = '012345678' FROM Designer WHERE DesignerID = 'SMI01'. C) UPDATE Designer SET PhoneNo = '012345678' WHERE DesignerID = 'SMI01'. D) UPDATE Designer (PhoneNo) VALUES ('012345678'). Show Answer Correct Answer: C) UPDATE Designer SET PhoneNo = '012345678' WHERE DesignerID = 'SMI01'. 25. What does the SQL statement 'SELECT * FROM world WHERE name = Algeria' do? A) Retrieves all fields of the record for Algeria from the 'world' table. B) Deletes the record of Algeria from the 'world' table. C) Updates all fields of the record for Algeria in the 'world' table. D) Inserts a new record for Algeria into the 'world' table. Show Answer Correct Answer: A) Retrieves all fields of the record for Algeria from the 'world' table. ← PreviousNext →Related QuizzesClass 12 Computer Science Chapter 4 Structured Query Language (Sql) Quiz 1Class 12 Computer Science Chapter 4 Structured Query Language (Sql) Quiz 3Class 12 Computer Science Chapter 4 Structured Query Language (Sql) Quiz 4Class 12 Computer Science Chapter 4 Structured Query Language (Sql) Quiz 5Class 12 Computer Science Chapter 4 Structured Query Language (Sql) Quiz 6Class 12 Computer Science Chapter 4 Structured Query Language (Sql) Quiz 7Class 12 Accountancy Chapter 1 Accounting For Partnership Firms Fundamentals QuizClass 12 Accountancy Chapter 2 Accounting For Partnership Firms Admission Of A Partner QuizClass 12 Accountancy Chapter 3 Accounting For Partnership Firms Retirement Death Of A Partner QuizClass 12 Accountancy Chapter 4 Accounting For Companies Issue Of Shares QuizClass 12 Accountancy Chapter 5 Accounting For Companies Issue Of Debentures QuizClass 12 Accountancy Chapter 7 Financial Statements Of Companies QuizClass 12 Accountancy Chapter 8 Analysis Of Financial Statements QuizClass 12 Accountancy Chapter 9 Computerised Accounting System QuizClass 12 Biology Chapter 1 Reproduction In Organisms QuizClass 12 Biology Chapter 10 Microbes In Human Welfare QuizClass 12 Biology Chapter 11 Biotechnology Principles And Processes QuizClass 12 Biology Chapter 12 Biotechnology And Its Applications QuizClass 12 Biology Chapter 13 Organisms And Populations QuizClass 12 Biology Chapter 14 Ecosystem QuizClass 12 Biology Chapter 15 Biodiversity And Conservation QuizClass 12 Biology Chapter 16 Environmental Issues QuizClass 12 Biology Chapter 2 Sexual Reproduction In Flowering Plants QuizClass 12 Biology Chapter 3 Human Reproduction QuizClass 12 Biology Chapter 4 Reproductive Health QuizClass 12 Biology Chapter 5 Principles Of Inheritance And Variation QuizClass 12 Biology Chapter 6 Molecular Basis Of Inheritance QuizClass 12 Biology Chapter 7 Evolution QuizClass 12 Biology Chapter 8 Human Health And Disease QuizClass 12 Biology Chapter 9 Strategies For Enhancement In Food Production QuizClass 12 Business Studies Chapter 1 Nature And Significance Of Management QuizClass 12 Business Studies Chapter 10 Financial Markets QuizClass 12 Business Studies Chapter 11 Marketing Management QuizClass 12 Business Studies Chapter 12 Consumer Protection QuizClass 12 Business Studies Chapter 2 Principles Of Management QuizClass 12 Business Studies Chapter 3 Business Environment QuizClass 12 Business Studies Chapter 4 Planning QuizClass 12 Business Studies Chapter 5 Organising QuizClass 12 Business Studies Chapter 6 Staffing QuizClass 12 Business Studies Chapter 7 Directing QuizClass 12 Business Studies Chapter 8 Controlling QuizClass 12 Business Studies Chapter 9 Financial Management QuizClass 12 Chemistry (Part I) Chapter 1 Solid State QuizClass 12 Chemistry (Part I) Chapter 2 Solutions QuizClass 12 Chemistry (Part I) Chapter 3 Electrochemistry QuizClass 12 Chemistry (Part I) Chapter 4 Chemical Kinetics QuizClass 12 Chemistry (Part I) Chapter 5 Surface Chemistry QuizClass 12 Chemistry (Part Ii) Chapter 10 Haloalkanes And Haloarenes QuizClass 12 Chemistry (Part Ii) Chapter 11 Alcohols QuizClass 12 Chemistry (Part Ii) Chapter 12 Aldehydes QuizClass 12 Chemistry (Part Ii) Chapter 13 Amines QuizClass 12 Chemistry (Part Ii) Chapter 14 Biomolecules QuizClass 12 Chemistry (Part Ii) Chapter 15 Polymers QuizClass 12 Chemistry (Part Ii) Chapter 16 Chemistry In Everyday Life QuizClass 12 Chemistry (Part Ii) Chapter 7 P Block Elements QuizClass 12 Chemistry (Part Ii) Chapter 8 D And F Block Elements QuizClass 12 Chemistry (Part Ii) Chapter 9 Coordination Compounds QuizClass 12 Computer Science Chapter 1 Data Structures Using Python QuizClass 12 Computer Science Chapter 2 Advanced Python Programming QuizClass 12 Computer Science Chapter 3 Database Management Systems QuizClass 12 Computer Science Chapter 5 Networking And Cyber Security QuizClass 12 Computer Science Chapter 6 Boolean Algebra And Logic Gates QuizClass 12 Economics (Indian Economic Development) Chapter 1 Development Experience (1947 90) And Economic Reforms Since 1991 QuizClass 12 Economics (Indian Economic Development) Chapter 2 Current Challenges Facing The Indian Economy QuizClass 12 Economics (Indian Economic Development) Chapter 3 Development Experience Of India A Comparison With Neighbours QuizClass 12 Economics (Macro Economics) Chapter 1 Introduction QuizClass 12 Economics (Macro Economics) Chapter 2 National Income Accounting QuizClass 12 Economics (Macro Economics) Chapter 3 Money And Banking QuizClass 12 Economics (Macro Economics) Chapter 4 Determination Of Income And Employment QuizClass 12 Economics (Macro Economics) Chapter 5 Government Budget And The Economy QuizClass 12 Economics (Macro Economics) Chapter 6 Open Economy Macroeconomics QuizClass 12 English (Flamingo) Chapter 1 The Last Lesson QuizClass 12 English (Flamingo) Chapter 2 Lost Spring QuizClass 12 English (Flamingo) Chapter 3 Deep Water QuizClass 12 English (Flamingo) Chapter 4 The Rattrap QuizClass 12 English (Flamingo) Chapter 5 Indigo QuizClass 12 English (Flamingo) Chapter 6 Poets And Pancakes QuizClass 12 English (Flamingo) Chapter 7 The Interview QuizClass 12 English (Flamingo) Chapter 8 Going Places QuizClass 12 English (Vistas) Chapter 1 The Third Level QuizClass 12 English (Vistas) Chapter 2 The Tiger King QuizClass 12 English (Vistas) Chapter 3 Journey To The End Of The Earth QuizClass 12 English (Vistas) Chapter 4 The Enemy QuizClass 12 English (Vistas) Chapter 5 Should Wizard Hit Mommy QuizClass 12 English (Vistas) Chapter 6 On The Face Of It QuizClass 12 English (Vistas) Chapter 7 Evans Tries An O Level QuizClass 12 English (Vistas) Chapter 8 Memories Of Childhood QuizClass 12 Entrepreneurship Chapter 1 Entrepreneurship And Enterprise QuizClass 12 Entrepreneurship Chapter 2 Entrepreneurial Planning QuizClass 12 Entrepreneurship Chapter 3 Project Formulation And Analysis QuizClass 12 Entrepreneurship Chapter 4 Enterprise Growth And Expansion QuizClass 12 Entrepreneurship Chapter 5 Business Ethics And Corporate Social Responsibility QuizClass 12 Entrepreneurship Chapter 6 Government Policies And Support To Entrepreneurship QuizClass 12 Entrepreneurship Chapter 7 Managing A Growing Enterprise QuizClass 12 Fine Arts Chapter 1 Elements And Principles Of Design QuizClass 12 Fine Arts Chapter 2 Advanced Colour Theory QuizClass 12 Fine Arts Chapter 3 Drawing And Painting Techniques QuizClass 12 Fine Arts Chapter 4 Art Movements Modern And Contemporary QuizClass 12 Fine Arts Chapter 7 Exhibition And Critique QuizClass 12 Geography Chapter 1 Human Geography Nature And Scope QuizClass 12 Geography Chapter 10 Disaster Management QuizClass 12 Geography Chapter 2 Population And Human Settlements QuizClass 12 Geography Chapter 3 Human Development QuizClass 12 Geography Chapter 4 Transport And Communication QuizClass 12 Geography Chapter 5 Primary Activities QuizClass 12 Geography Chapter 6 Secondary Activities QuizClass 12 Geography Chapter 7 Tertiary And Quaternary Activities QuizClass 12 Geography Chapter 8 Regional Development QuizClass 12 Geography Chapter 9 Environmental Geography QuizClass 12 History Chapter 1 The Rise Of Nationalism In Europe QuizClass 12 History Chapter 10 The Cold War Era QuizClass 12 History Chapter 2 Nationalism In India QuizClass 12 History Chapter 3 The Making Of A Global World QuizClass 12 History Chapter 4 The Age Of Industrialisation QuizClass 12 History Chapter 5 Print Culture And The Modern World QuizClass 12 History Chapter 6 The First World War QuizClass 12 History Chapter 7 The Interwar Years QuizClass 12 History Chapter 8 The Second World War QuizClass 12 Home Science Chapter 2 Fabric And Apparel QuizClass 12 Home Science Chapter 3 Food And Nutrition QuizClass 12 Home Science Chapter 4 Human Development QuizClass 12 Home Science Chapter 5 Adolescence And Life Skills QuizClass 12 Home Science Chapter 7 Textiles And Clothing QuizClass 12 Mathematics Chapter 1 Relations And Functions QuizClass 12 Mathematics Chapter 10 Vector Algebra QuizClass 12 Mathematics Chapter 11 Three Dimensional Geometry QuizClass 12 Mathematics Chapter 12 Linear Programming QuizClass 12 Mathematics Chapter 13 Probability QuizClass 12 Mathematics Chapter 2 Inverse Trigonometric Functions QuizClass 12 Mathematics Chapter 3 Matrices QuizClass 12 Mathematics Chapter 4 Determinants QuizClass 12 Mathematics Chapter 5 Continuity And Differentiability QuizClass 12 Mathematics Chapter 6 Applications Of Derivatives QuizClass 12 Mathematics Chapter 7 Integrals QuizClass 12 Mathematics Chapter 8 Applications Of Integrals QuizClass 12 Mathematics Chapter 9 Differential Equations QuizClass 12 Philosophy Chapter 1 Philosophy And Its Relation With Other Disciplines QuizClass 12 Philosophy Chapter 2 Epistemology The Theory Of Knowledge QuizClass 12 Philosophy Chapter 3 Metaphysics QuizClass 12 Philosophy Chapter 4 Ethics QuizClass 12 Philosophy Chapter 5 Indian Philosophy Classical Traditions QuizClass 12 Philosophy Chapter 6 Modern Western Philosophy QuizClass 12 Philosophy Chapter 7 Philosophy In Contemporary Times QuizClass 12 Physical Education Chapter 1 Management Of Sports And Physical Activity QuizClass 12 Physical Education Chapter 2 Planning In Sports QuizClass 12 Physical Education Chapter 3 Children And Women In Sports QuizClass 12 Physical Education Chapter 4 Test, Measurement And Evaluation In Sports QuizClass 12 Physical Education Chapter 5 Kinesiology, Biomechanics And Sports QuizClass 12 Physical Education Chapter 6 Yoga And Lifestyle QuizClass 12 Physical Education Chapter 7 Physical Education And Leadership QuizClass 12 Physical Education Chapter 8 Training And Doping In Sports QuizClass 12 Physical Education Chapter 9 Physiology And Exercise QuizClass 12 Physics (Part I) Chapter 1 Electric Charges And Fields QuizClass 12 Physics (Part I) Chapter 2 Electrostatic Potential And Capacitance QuizClass 12 Physics (Part I) Chapter 3 Current Electricity QuizClass 12 Physics (Part I) Chapter 4 Moving Charges And Magnetism QuizClass 12 Physics (Part I) Chapter 5 Magnetism And Matter QuizClass 12 Physics (Part I) Chapter 6 Electromagnetic Induction QuizClass 12 Physics (Part I) Chapter 7 Alternating Current QuizClass 12 Physics (Part I) Chapter 8 Electromagnetic Waves QuizClass 12 Physics (Part Ii) Chapter 10 Wave Optics QuizClass 12 Physics (Part Ii) Chapter 11 Dual Nature Of Radiation And Matter QuizClass 12 Physics (Part Ii) Chapter 12 Atoms QuizClass 12 Physics (Part Ii) Chapter 13 Nuclei QuizClass 12 Physics (Part Ii) Chapter 14 Semiconductor Electronics Materials QuizClass 12 Physics (Part Ii) Chapter 9 Ray Optics And Optical Instruments QuizClass 12 Political Science Chapter 1 Challenges Of Nation Building QuizClass 12 Political Science Chapter 10 Challenges To Democracy QuizClass 12 Political Science Chapter 2 Planning And Development QuizClass 12 Political Science Chapter 3 India'S Foreign Policy QuizClass 12 Political Science Chapter 4 India After Independence QuizClass 12 Political Science Chapter 5 Democracy And Diversity QuizClass 12 Political Science Chapter 6 Gender, Religion And Caste QuizClass 12 Political Science Chapter 7 Popular Struggles And Movements QuizClass 12 Political Science Chapter 8 Politics Of Planned Development QuizClass 12 Political Science Chapter 9 India'S External Relations QuizClass 12 Psychology Chapter 1 Variations In Psychological Attributes QuizClass 12 Psychology Chapter 10 Industrial Organisational Psychology QuizClass 12 Psychology Chapter 2 Self And Personality QuizClass 12 Psychology Chapter 3 Meeting Life Challenges QuizClass 12 Psychology Chapter 4 Psychological Disorders QuizClass 12 Psychology Chapter 5 Therapies QuizClass 12 Psychology Chapter 6 Attitude And Social Cognition QuizClass 12 Psychology Chapter 7 Social Influence And Group Processes QuizClass 12 Psychology Chapter 8 Psychology And Life QuizClass 12 Psychology Chapter 9 Applications Of Psychology QuizClass 12 Sociology Chapter 1 Structural Change And Development In India QuizClass 12 Sociology Chapter 3 The Demographic Structure Of Indian Society QuizClass 12 Sociology Chapter 5 Patterns Of Social Inequality And Exclusion QuizClass 12 Sociology Chapter 6 Challenges Of Cultural Diversity QuizClass 12 Sociology Chapter 8 Social Change In Modern India QuizClass 12 Sociology Chapter 9 Globalisation And Social Change Quiz 🏠 Back to Homepage 📘 Download PDF Books 📕 Premium PDF Books