SQL VIEW क्या है?
Last Updated:
Last Updated:
VIEW SQL query के result पर आधारित virtual table है।
FAQ
Common questions and clear answers for this topic.
A Database is an organized collection of structured data stored electronically in a computer system. It allows easy access, management, and updating of data. Databases are essential in modern applications like banking systems, e-commerce websites, hospital records, and social media platforms. Common database types include Relational (SQL) and Non-Relational (NoSQL) databases.
SQL databases are relational, store data in structured tables with fixed schema, and use SQL for queries. Examples: MySQL, PostgreSQL, Oracle. NoSQL databases are non-relational, store data in flexible formats like documents, key-value pairs, or graphs. Examples: MongoDB, Redis, Cassandra. SQL is better for complex queries; NoSQL is better for large-scale unstructured data.
ACID properties ensure reliable database transactions: Atomicity (transaction is all-or-nothing), Consistency (database remains in a valid state), Isolation (concurrent transactions do not interfere), and Durability (committed transactions are permanently saved). These properties are critical in banking and financial applications where data integrity is essential.
Normalization is the process of organizing a database to reduce data redundancy and improve data integrity. Normal forms include 1NF (eliminate repeating groups), 2NF (remove partial dependencies), 3NF (remove transitive dependencies), and BCNF. Normalization divides large tables into smaller related tables. It is a common SQL interview topic in software engineering interviews.
A Primary Key uniquely identifies each record in a table and cannot be NULL or duplicate. A Foreign Key is a field in one table that refers to the Primary Key in another table, creating a relationship between tables. For example, in a student database, StudentID is the Primary Key in the Students table and a Foreign Key in the Marks table.