DBMS Interview Questions and Answers (updated)
Q1. What is a DBMS?
Ans: DBMS stands for Database Management System. A DBMS receives requests from applications and interprets the ones requests into movements on a selected database.
A DBMS approaches SQL statements or makes use of different capability to create, method and administer databases.
Q2. What is a Database system?
Ans: The database and DBMS software program together is called as Database device.
Q3. What is Trigger?
Ans: When database are inserted, deleted or updated, a procedure is completed in response to that movement. Such SQL procedure are called as cause.
Q4. What is Data Independence?
Ans: Data independence manner that ?The application is unbiased of the garage shape and get entry to strategy of information?. In other words, The capability to alter the schema definition in one degree should now not have an effect on the schema definition within the next better level.
Two kinds of Data Independence:
Physical Data Independence : Modification in bodily degree have to now not affect the logical stage.
Logical Data Independence : Modification in logical level should affect the view stage.
Q5. Define sub question?
Ans: Sub-Query is likewise called as Nested Query. Sub-Query is a question within any other question. Sub-Query may be used with SELECT, INSERT, UPDATE and DELETE Statement.
Q6. What are data and facts, and how are they associated in a database?
Ans: Data is recorded data and figures, and facts is knowledge derived from information. A database shops information in one of these way that data may be created.
Q7. What is Normalization?
Ans: Normalization is procedure of organizing database. Normalization procedure usually entails doing away with or casting off redundancy facts from fields and tables of relational database.
Q8. What is an Entity?
Ans: It is a 'thing' in the actual global with an independent lifestyles.
Q9. What are the advantages of DBMS?
Ans: The blessings of DBMS are as follows:
Redundancy is managed
Unauthorised access is limited
Providing a couple of person interfaces
Enforcing integrity constraints
Providing backup and get better
Q10. What is a view? How it's far associated with statistics independence?
Ans: A view may be concept of as a digital table, that is, a table that doesn't really exist in its very own right but is alternatively derived from one or more underlying base table. In different phrases, there is no stored file that direct represents the view as a substitute a definition of view is saved in data dictionary.
Growth and restructuring of base tables isn't always meditated in perspectives. Thus the view can insulate customers from the effects of restructuring and growth inside the database. Hence money owed for logical records independence. .
Q11. Why is a database taken into consideration to be "self-describing"?
Ans: In addition to the users' records, a database incorporates an outline of its personal shape. This descriptive data is referred to as "metadata."
Q12. What is normalization?
Ans: It is a process of analysing the given relation schemas primarily based on their Functional Dependencies (FDs) and number one key to obtain the houses
Minimizing insertion, deletion and replace anomalies.
Q13. What is Data Model?
Ans: A series of conceptual equipment for describing statistics, facts relationships records semantics and constraints.
Q14. What are extraordinary forms of Normalization?
Ans: There are one of a kind varieties of Normalization. They are: First Normal Form(1NF), Second Normal Form(2NF), Third Normal Form(3NF), Fourth Normal Form(4NF) and Boyce-Codd Normal Form (BCNF)
Q15. What is SQL, and why is it important?
Ans: SQL stands for Structured Query Language, and is the most crucial records processing language in use these days. It is not a whole programming language like Java or C#, however a information sublanguage used for creating and processing database information and metadata. All DBMS products today use SQL.
Q16. What are the kinds of constraint?
Ans: NOT NULL, UNIQUE, PRIMARY KEY, FOREIGN KEY, CHECK and DEFAULT are some of constraints.
Q17. What is E-R version?
Ans: This information version is based totally on actual world that consists of basic objects known as entities and of dating among these objects. Entities are defined in a database by way of a set of attributes.
Q18. Define constraint?
Ans: Constraint in database set certain policies or property in a table. Suppose if a row has NOT NULL constraint, then it can not have any null values.
Q19. Write an SQL SELECT declaration to display all of the columns of the STUDENT table but handiest those rows in which the Grade column is extra than or same to 90.
Ans: SELECT * FROM STUDENT WHERE Grade >= ninety;
Q20. Difference between delete and truncate?
Delete statement is used to delete selected rows from database tables while truncate announcement deletes all rows from desk.
Delete assertion is slower than truncate declaration.
Truncate is DML(Data Manipulation Language) command and Delete is DDL(Data Definition Language) command.
Q21. What is Object Oriented model?
Ans: This version is based totally on collection of items. An object incorporates values stored in instance variables with in the item. An item also carries bodies of code that function at the item. These our bodies of code are known as strategies. Objects that include equal styles of values and the equal techniques are grouped together into training.
Q22. Define index? Types of index?
Ans: Index is used for quicker retrieval of statistics store and speedup question performance. There are sorts of index, clustered index and non-clustered index.
Q23. Whats difference between DBMS and RDBMS?
Ans: DBMS offers a systematic and prepared manner of storing, managing and retrieving from collection of logically related statistics. RDBMS also presents what DBMS gives however above that it provides courting integrity.
Q24. What are combination and scalar functions?
Ans: Aggregate functions are used to assess mathematical calculation and return single values. This may be calculated from the columns in a desk. Scalar functions go back a unmarried fee primarily based on the input fee.
Example:Aggregate – max(), count – Calculated with recognize to numeric.
Scalar – UCASE(), NOW() – Calculated with admire to strings.
Q25. What is Union, minus and Interact instructions?
Ans: MINUS operator is used to return rows from the primary question however now not from the second one question. INTERSECT operator is used to return rows back through each the queries.
Q26. How to create database?
Ans: Database can be created by way of ‘CREATE DATABASE’ Statements. For Example: CREATE DATABASE dbname;
Q27. What is an characteristic?
Ans: It is a selected belongings, which describes the entity.
Q28. What is collation?
Ans: Collation is defined as set of regulations that decide how character records may be sorted and compared. This can be used to evaluate A and, other language characters and also depends on the width of the characters.
ASCII price may be used to examine these person records.
Q29. What is DML (Data Manipulation Language)?
Ans: This language that enable user to get admission to or manipulate records as organised by suitable records version.
Procedural DML or Low degree: DML requires a user to specify what facts are wanted and the way to get those information.
Non -Procedural DML or High stage:DML requires a user to specify what data are wanted without specifying how to get those facts.
Q30. What is SQL Join?
Ans: SQL join are used for retrieving facts and information from or greater tables. SQL Join combine two or greater table(or row).
Q31. What is Stored Procedure?
Ans: A saved technique is a named organization of SQL statements which have been previously created and stored within the server database.
Q32. What is Cross-Join?
Ans: Cross be part of defines as Cartesian product in which variety of rows within the first table extended with the aid of number of rows in the second table. If suppose, WHERE clause is used in pass be a part of then the question will paintings like an INNER JOIN.
Q33. What is DML Compiler?
Ans: It translates DML statements in a query language into low-stage preparation that the query evaluation engine can recognize.
Q34. How to create Table?
Ans: For growing a Table in database, we must use ‘CREATE TABLE’ Statement.
CREATE TABLE “SomeName”
Q35. What is a Cursor?
Ans: A database Cursor is a manipulate which enables traversal over the rows or information in the desk. This can be viewed as a pointer to 1 row in a hard and fast of rows. Cursor could be very tons useful for traversing which includes retrieval, addition and removal of database statistics.