121 Question 121 EN + हिं Easy GB What is CREATE TEMPORARY TABLE and what is its scope? IN क्रिएट टेम्परेरी टेबल क्या है और इसका दायरा क्या है? A Creates a table that is read-only एक तालिका बनाता है जो केवल पढ़ने योग्य है B Creates a table that is shared across all sessions but deleted after 24 hours एक तालिका बनाता है जिसे सभी सत्रों में साझा किया जाता है लेकिन 24 घंटों के बाद हटा दिया जाता है C Creates a table in a temporary schema visible to all users सभी उपयोगकर्ताओं के लिए दृश्यमान एक अस्थायी स्कीमा में एक तालिका बनाता है D Creates a table that is visible only to the current session and is automatically dropped when the session ends or connection closes एक तालिका बनाता है जो केवल वर्तमान सत्र के लिए दृश्यमान होती है और सत्र समाप्त होने या कनेक्शन बंद होने पर स्वचालित रूप से हटा दी जाती है ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) Temporary tables: session-scoped, visible only to the creating session (other sessions cannot see it), automatically dropped on session end. Useful for: storing intermediate results, breaking complex queries into steps, avoiding repeated subquery execution. व्याख्या (हिन्दी) अस्थायी तालिकाएँ: सत्र-क्षेत्र, केवल निर्माण सत्र के लिए दृश्यमान (अन्य सत्र इसे नहीं देख सकते), सत्र के अंत में स्वचालित रूप से हटा दी जाती हैं। इसके लिए उपयोगी: मध्यवर्ती परिणामों को संग्रहीत करना, जटिल प्रश्नों को चरणों में तोड़ना, बार-बार सबक्वेरी निष्पादन से बचना। 🎯 Exam Perspective DBMS ("DDL Commands" sub-topic) से जुड़ा यह सवाल — difficulty level "Easy" उन students के लिए काम का है जो SSC CGL, IBPS, RRB और State-level परीक्षाओं की तैयारी कर रहे हैं। बेहतर होगा कि explanation पढ़कर concept clear करें, ताकि exam में similar प्रश्न आने पर confusion न हो। 🔗 Related Questions What is the purpose of CREATE ASSERTION statement in st... What is the SQL standard CREATE VIEW statement and what... In DDL what is the difference between CONSTRAINT constr... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
122 Question 122 EN + हिं Medium GB What is the purpose of GRANT and REVOKE statements in SQL and which classification do they fall under? IN SQL में GRANT और REVOKE स्टेटमेंट का उद्देश्य क्या है और वे किस वर्गीकरण के अंतर्गत आते हैं? A They are DDL statements for schema management वे स्कीमा प्रबंधन के लिए डीडीएल स्टेटमेंट हैं B They are DML statements for data manipulation वे डेटा हेरफेर के लिए डीएमएल स्टेटमेंट हैं C They are DQL statements for querying data वे डेटा को क्वेरी करने के लिए DQL स्टेटमेंट हैं D They are DCL (Data Control Language) statements - GRANT gives specific privileges (SELECT, INSERT, UPDATE, DELETE, EXECUTE) to users/roles on database objects; REVOKE removes those privileges वे डीसीएल (डेटा कंट्रोल लैंग्वेज) स्टेटमेंट हैं - ग्रांट डेटाबेस ऑब्जेक्ट्स पर उपयोगकर्ताओं/भूमिकाओं को विशिष्ट विशेषाधिकार (चयन, सम्मिलित करें, अपडेट करें, हटाएं, निष्पादित करें) देता है; REVOKE उन विशेषाधिकारों को हटा देता है ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) DCL (Data Control Language): GRANT and REVOKE manage access control. GRANT SELECT ON employees TO analyst_role. REVOKE INSERT ON employees FROM contractor. Privileges can be object-level (table, column, view, function), system-level, or role-based. व्याख्या (हिन्दी) DCL (Data Control Language): GRANT and REVOKE manage access control. GRANT SELECT ON employees TO analyst_role. ठेकेदार से कर्मचारियों पर इंसर्ट रद्द करें। Privileges can be object-level (table, column, view, function), system-level, or role-based. 🎯 Exam Perspective UPSC, SSC, Banking और Police भर्ती जैसी परीक्षाओं में DBMS ("DDL Commands" sub-topic) से सवाल अक्सर पूछे जाते हैं — difficulty level "Medium"। इसलिए सिर्फ answer रटने के बजाय, नीचे दी गई explanation को ध्यान से पढ़ें और concept समझें। 🔗 Related Questions What is the difference between a UNIQUE constraint and... What is the SQL standard way to add a FOREIGN KEY to an... What is the SQL COMMENT statement and how is metadata t... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
123 Question 123 EN + हिं Easy GB What is the SQL standard way to add a FOREIGN KEY to an existing table? IN किसी मौजूदा तालिका में विदेशी कुंजी जोड़ने का SQL मानक तरीका क्या है? A FOREIGN KEY cannot be added to existing tables only during CREATE TABLE केवल CREATE TABLE के दौरान विदेशी कुंजी को मौजूदा तालिकाओं में नहीं जोड़ा जा सकता है B ALTER TABLE child ADD COLUMN parent_id REFERENCES parent तालिका बदलें चाइल्ड कॉलम जोड़ें पैरेंट_आईडी संदर्भ पैरेंट C ALTER TABLE child SET FOREIGN KEY = parent_col परिवर्तन तालिका चाइल्ड सेट विदेशी कुंजी =parent_col D ALTER TABLE child ADD CONSTRAINT fk_name FOREIGN KEY (child_col) REFERENCES parent_table(parent_col) ON DELETE CASCADE ON UPDATE CASCADE तालिका में परिवर्तन करने वाले बच्चे के लिए बाधा जोड़ें fk_name विदेशी कुंजी (child_col) संदर्भ पैरेंट_टेबल (parent_col) अद्यतन कैस्केड पर कैस्केड हटाएं ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) Syntax: ALTER TABLE orders ADD CONSTRAINT fk_customer FOREIGN KEY (customer_id) REFERENCES customers(id) ON DELETE RESTRICT ON UPDATE CASCADE. This adds the FK constraint, verifies existing data conforms, and enforces referential integrity going forward. व्याख्या (हिन्दी) सिंटैक्स: परिवर्तन तालिका आदेश अद्यतन कैस्केड पर हटाएं प्रतिबंध पर बाधा एफके_ग्राहक विदेशी कुंजी (ग्राहक_आईडी) संदर्भ ग्राहक (आईडी) जोड़ें। यह एफके बाधा जोड़ता है, मौजूदा डेटा अनुरूपता को सत्यापित करता है, और आगे बढ़ने वाली संदर्भात्मक अखंडता को लागू करता है। 🎯 Exam Perspective अगर आप Railway, SSC, Banking और Defence परीक्षाओं की तैयारी कर रहे हैं, तो DBMS ("DDL Commands" sub-topic) का यह topic आपके लिए महत्वपूर्ण है — difficulty level "Easy"। Exam में accuracy बढ़ाने के लिए हर सवाल की explanation जरूर पढ़ें। 🔗 Related Questions What is the SQL standard CREATE VIEW statement and what... DROP TABLE removes What is online schema change (OSC) and why is it needed... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
124 Question 124 EN + हिं Medium GB What is online schema change (OSC) and why is it needed? IN ऑनलाइन स्कीमा परिवर्तन (ओएससी) क्या है और इसकी आवश्यकता क्यों है? A A technique/tool that allows schema modifications on large production tables without long table locks or downtime typically by creating a shadow table copying data incrementally and atomically swapping the tables एक तकनीक/उपकरण जो लंबे टेबल लॉक या डाउनटाइम के बिना बड़ी उत्पादन तालिकाओं पर स्कीमा संशोधन की अनुमति देता है, आमतौर पर एक छाया तालिका बनाकर डेटा को वृद्धिशील रूप से कॉपी करता है और तालिकाओं को परमाणु रूप से स्वैप करता है। B A standard SQL feature for non-locking DDL नॉन-लॉकिंग DDL के लिए एक मानक SQL सुविधा C A tool for changing schemas via a web browser वेब ब्राउज़र के माध्यम से स्कीमा बदलने के लिए एक उपकरण D A method for replicating schema changes across distributed databases वितरित डेटाबेस में स्कीमा परिवर्तनों की प्रतिकृति बनाने की एक विधि ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) OSC tools (pt-online-schema-change, gh-ost): create a new table with desired schema, copy data in chunks while capturing ongoing changes (via triggers or binlog), then atomically rename new table to replace old. Avoids long table locks that would block production traffic. व्याख्या (हिन्दी) ओएससी उपकरण (पीटी-ऑनलाइन-स्कीमा-चेंज, जीएच-ओस्ट): वांछित स्कीमा के साथ एक नई तालिका बनाएं, चल रहे परिवर्तनों (ट्रिगर या बिनलॉग के माध्यम से) को कैप्चर करते समय डेटा को टुकड़ों में कॉपी करें, फिर पुराने को बदलने के लिए परमाणु रूप से नई तालिका का नाम बदलें। Avoids long table locks that would block production traffic. 🎯 Exam Perspective DBMS ("DDL Commands" sub-topic) के इस प्रश्न को — difficulty level "Medium" कई प्रतियोगी परीक्षाओं जैसे SSC, Railway, Banking और State PCS में repeat होते देखा गया है। Concept clarity के लिए explanation section जरूर पढ़ें। 🔗 Related Questions What is the purpose of ALTER TABLE RENAME and does it a... What is the SQL standard way to add a FOREIGN KEY to an... What is the purpose of GRANT and REVOKE statements in S... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
125 Question 125 EN + हिं Medium GB What is the purpose of CREATE ASSERTION statement in standard SQL? IN मानक SQL में CREATE ASSERTION स्टेटमेंट का उद्देश्य क्या है? A To assert that a column cannot be NULL यह दावा करने के लिए कि कोई कॉलम NULL नहीं हो सकता B A named constraint that can span multiple tables (unlike table-level CHECK constraints which are limited to one table) - allows complex business rules to be defined at the schema level एक नामित बाधा जो कई तालिकाओं तक फैल सकती है (तालिका-स्तरीय CHECK बाधाओं के विपरीत जो एक तालिका तक सीमित हैं) - जटिल व्यावसायिक नियमों को स्कीमा स्तर पर परिभाषित करने की अनुमति देती है C To create a trigger that asserts conditions एक ट्रिगर बनाने के लिए जो शर्तों पर जोर देता है D To create database assertions/documentation डेटाबेस दावे/दस्तावेज़ीकरण बनाने के लिए ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) CREATE ASSERTION is SQL standard for complex multi-table constraints. CREATE ASSERTION max_salary CHECK (NOT EXISTS (SELECT * FROM Emp WHERE salary > 200000)). Checked after every DML statement. Most DBMS do not fully implement assertions; triggers are used instead. व्याख्या (हिन्दी) CREATE ASSERTION is SQL standard for complex multi-table constraints. CREATE ASSERTION max_salary CHECK (NOT EXISTS (SELECT * FROM Emp WHERE salary > 200000)). प्रत्येक डीएमएल विवरण के बाद जाँच की गई। अधिकांश DBMS दावे को पूरी तरह से लागू नहीं करते हैं; इसके बजाय ट्रिगर्स का उपयोग किया जाता है। 🎯 Exam Perspective यह सवाल DBMS ("DDL Commands" sub-topic) category का है — difficulty level "Medium", और SSC CGL, IBPS, RRB और State-level परीक्षाओं के exam pattern में इस तरह के questions common हैं। Answer choose करने के बाद दिया गया explanation जरूर पढ़ें। 🔗 Related Questions What does INHERITS clause do in PostgreSQL CREATE TABLE... What is the effect of DROP COLUMN on a table with index... Which DDL command modifies column data type 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
126 Question 126 EN + हिं Easy GB What does INHERITS clause do in PostgreSQL CREATE TABLE? IN PostgreSQL क्रिएट टेबल में INHERITS क्लॉज क्या करता है? A It inherits column permissions from another table यह किसी अन्य तालिका से कॉलम अनुमतियाँ प्राप्त करता है B Creates a child table that inherits all columns and constraints from a parent table with child-specific additional columns - part of PostgreSQLs table inheritance feature for object-relational capabilities एक चाइल्ड टेबल बनाता है जो चाइल्ड-विशिष्ट अतिरिक्त कॉलम के साथ पैरेंट टेबल से सभी कॉलम और बाधाओं को प्राप्त करता है - ऑब्जेक्ट-रिलेशनल क्षमताओं के लिए PostgreSQLs टेबल इनहेरिटेंस सुविधा का हिस्सा C It is identical to FOREIGN KEY inheritance यह विदेशी कुंजी वंशानुक्रम के समान है D It makes the table read-only inheriting data from parent यह तालिका को माता-पिता से प्राप्त डेटा को केवल पढ़ने योग्य बनाता है ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) PostgreSQL table inheritance: CREATE TABLE employee (salary NUMERIC) INHERITS (person). Employee has all person columns plus salary. Queries on person return data from employee too (unless ONLY keyword used). Useful for partitioning-like patterns, though declarative partitioning is now preferred. व्याख्या (हिन्दी) PostgreSQL table inheritance: CREATE TABLE employee (salary NUMERIC) INHERITS (person). कर्मचारी के पास सभी व्यक्ति कॉलम प्लस वेतन हैं। Queries on person return data from employee too (unless ONLY keyword used). Useful for partitioning-like patterns, though declarative partitioning is now preferred. 🎯 Exam Perspective यह प्रश्न DBMS ("DDL Commands" sub-topic) की तैयारी करने वाले अभ्यर्थियों के लिए उपयोगी है — difficulty level "Easy"। इस तरह के प्रश्न अक्सर UPSC, SSC, Banking और Police भर्ती जैसी परीक्षाओं में पूछे जाते रहे हैं, इसलिए concept और explanation दोनों को ध्यान से समझें, सिर्फ उत्तर याद न करें। 🔗 Related Questions What is the purpose of GRANT and REVOKE statements in S... What is the SQL standard CREATE VIEW statement and what... What is the purpose of CREATE ASSERTION statement in st... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
127 Question 127 EN + हिं Medium GB In DDL what is the difference between CONSTRAINT constraint_name PRIMARY KEY defined at column level vs table level? IN डीडीएल में कॉलम स्तर बनाम तालिका स्तर पर परिभाषित CONSTRAINT constraint_name PRIMARY KEY के बीच क्या अंतर है? A Table-level constraints are always anonymous तालिका-स्तरीय बाधाएँ हमेशा गुमनाम होती हैं B Column-level constraints are stronger कॉलम-स्तर की बाधाएँ अधिक मजबूत हैं C Column-level: can only define single-column constraints; Table-level: can define single or multi-column (composite) constraints and allows explicit naming at the table level - functionally equivalent for single-column but ONLY table-level syntax works for composite keys Column-level: can only define single-column constraints; तालिका-स्तर: एकल या बहु-स्तंभ (मिश्रित) बाधाओं को परिभाषित कर सकता है और तालिका स्तर पर स्पष्ट नामकरण की अनुमति देता है - एकल-स्तंभ के लिए कार्यात्मक रूप से समतुल्य लेकिन समग्र कुंजियों के लिए केवल तालिका-स्तरीय सिंटैक्स काम करता है D Table-level constraints apply to the entire table; column-level to one column only Table-level constraints apply to the entire table; कॉलम-स्तर केवल एक कॉलम तक ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) Column-level: salary NUMERIC CONSTRAINT chk_salary CHECK(salary>0) - only for single column. Table-level: CONSTRAINT pk_emp PRIMARY KEY (emp_id, dept_id) - required for composite keys. For composite PK, FK, or UNIQUE involving multiple columns, MUST use table-level syntax. व्याख्या (हिन्दी) कॉलम-स्तर: वेतन संख्यात्मक बाधा chk_वेतन चेक(वेतन>0) - केवल एकल कॉलम के लिए। तालिका-स्तर: CONSTRAINT pk_emp प्राथमिक कुंजी (emp_id, dept_id) - समग्र कुंजियों के लिए आवश्यक। अनेक स्तंभों वाले समग्र PK, FK, या UNIQUE के लिए, तालिका-स्तरीय सिंटैक्स का उपयोग अवश्य करें। 🎯 Exam Perspective DBMS ("DDL Commands" sub-topic) से जुड़ा यह सवाल — difficulty level "Medium" उन students के लिए काम का है जो Railway, SSC, Banking और Defence परीक्षाओं की तैयारी कर रहे हैं। बेहतर होगा कि explanation पढ़कर concept clear करें, ताकि exam में similar प्रश्न आने पर confusion न हो। 🔗 Related Questions DROP TABLE removes What is online schema change (OSC) and why is it needed... What is the SQL standard way to add a FOREIGN KEY to an... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
128 Question 128 EN + हिं Easy GB What is the effect of DROP COLUMN on a table with indexes and foreign keys referencing that column? IN उस कॉलम को संदर्भित करने वाली अनुक्रमणिका और विदेशी कुंजियों वाली तालिका पर DROP COLUMN का क्या प्रभाव होता है? A It silently preserves all indexes with NULL values for the dropped column यह गिराए गए कॉलम के लिए NULL मान वाले सभी इंडेक्स को चुपचाप संरक्षित करता है B It drops only the column data but keeps the indexes यह केवल कॉलम डेटा छोड़ता है लेकिन इंडेक्स रखता है C Most DBMS automatically drop all indexes that include the dropped column and reject the operation if any foreign key references the dropped column (requiring you to drop the FK first) - or CASCADE can be used to drop dependent objects too अधिकांश DBMS स्वचालित रूप से सभी इंडेक्स को हटा देते हैं जिसमें गिरा हुआ कॉलम शामिल होता है और यदि कोई विदेशी कुंजी गिराए गए कॉलम को संदर्भित करता है तो ऑपरेशन को अस्वीकार कर देता है (आपको पहले FK को छोड़ने की आवश्यकता होती है) - या CASCADE का उपयोग निर्भर वस्तुओं को छोड़ने के लिए भी किया जा सकता है D It converts the column to NULL before dropping यह ड्रॉप करने से पहले कॉलम को NULL में बदल देता है ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) DROP COLUMN behavior: dependent indexes on that column are automatically dropped. FK constraints referencing the column as a foreign key (in other tables) are typically rejected - you must DROP the FK first or use DROP COLUMN CASCADE (PostgreSQL). CHECK constraints using the column are also dropped. व्याख्या (हिन्दी) DROP COLUMN behavior: dependent indexes on that column are automatically dropped. कॉलम को एक विदेशी कुंजी (अन्य तालिकाओं में) के रूप में संदर्भित करने वाली FK बाधाओं को आम तौर पर अस्वीकार कर दिया जाता है - आपको पहले FK को छोड़ना होगा या DROP COLUMN CASCADE (PostgreSQL) का उपयोग करना होगा। CHECK constraints using the column are also dropped. 🎯 Exam Perspective SSC, Railway, Banking और State PCS जैसी परीक्षाओं में DBMS ("DDL Commands" sub-topic) से सवाल अक्सर पूछे जाते हैं — difficulty level "Easy"। इसलिए सिर्फ answer रटने के बजाय, नीचे दी गई explanation को ध्यान से पढ़ें और concept समझें। 🔗 Related Questions What is the purpose of CREATE ASSERTION statement in st... What is online schema change (OSC) and why is it needed... DROP TABLE removes 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
129 Question 129 EN + हिं Medium GB What is the SQL standard DEFAULT clause and how does it interact with INSERT statements? IN SQL मानक DEFAULT क्लॉज क्या है और यह INSERT कथनों के साथ कैसे इंटरैक्ट करता है? A DEFAULT is only for NOT NULL columns डिफ़ॉल्ट केवल शून्य नहीं कॉलम के लिए है B DEFAULT only applies to UPDATE statements not INSERT डिफ़ॉल्ट केवल अद्यतन विवरण पर लागू होता है INSERT पर नहीं C DEFAULT forces a column to always have the same value डिफ़ॉल्ट किसी कॉलम को हमेशा समान मान रखने के लिए बाध्य करता है D DEFAULT clause in CREATE TABLE specifies the value to use when an INSERT statement does not provide a value for that column - can be a literal value a function call (like NOW()) or a sequence reference CREATE TABLE में डिफ़ॉल्ट क्लॉज उस मूल्य को निर्दिष्ट करता है जिसका उपयोग तब किया जाना चाहिए जब एक INSERT कथन उस कॉलम के लिए कोई मान प्रदान नहीं करता है - एक फ़ंक्शन कॉल का शाब्दिक मान हो सकता है (जैसे NOW()) या एक अनुक्रम संदर्भ ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) DEFAULT clause: CREATE TABLE t (created_at TIMESTAMP DEFAULT NOW(), status VARCHAR(20) DEFAULT pending). INSERT INTO t (col1) VALUES (val1): created_at gets NOW(), status gets pending. INSERT INTO t (col1, status) VALUES (val1, DEFAULT): explicitly uses default value. व्याख्या (हिन्दी) डिफ़ॉल्ट क्लॉज: टेबल बनाएं (अभी टाइमस्टैम्प पर बनाया गया है(), स्थिति VARCHAR(20) डिफ़ॉल्ट लंबित है)। t (col1) मानों (val1) में सम्मिलित करें: create_at को अभी() मिलता है, स्थिति लंबित हो जाती है। टी (कॉल1, स्थिति) मानों में सम्मिलित करें (वैल1, डिफ़ॉल्ट): स्पष्ट रूप से डिफ़ॉल्ट मान का उपयोग करता है। 🎯 Exam Perspective अगर आप SSC CGL, IBPS, RRB और State-level परीक्षाओं की तैयारी कर रहे हैं, तो DBMS ("DDL Commands" sub-topic) का यह topic आपके लिए महत्वपूर्ण है — difficulty level "Medium"। Exam में accuracy बढ़ाने के लिए हर सवाल की explanation जरूर पढ़ें। 🔗 Related Questions What does INHERITS clause do in PostgreSQL CREATE TABLE... What is the SQL standard way to add a FOREIGN KEY to an... What is the SQL standard CREATE VIEW statement and what... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
130 Question 130 EN + हिं Medium GB What is the difference between a UNIQUE constraint and a UNIQUE index in most DBMS? IN अधिकांश DBMS में UNIQUE बाधा और UNIQUE सूचकांक के बीच क्या अंतर है? A Functionally they are equivalent in most DBMS - a UNIQUE constraint is typically implemented internally as a UNIQUE index; the difference is declarative (UNIQUE constraint) vs. explicit (CREATE UNIQUE INDEX) - both prevent duplicate values कार्यात्मक रूप से वे अधिकांश DBMS में समतुल्य हैं - एक UNIQUE बाधा आमतौर पर UNIQUE सूचकांक के रूप में आंतरिक रूप से लागू की जाती है; अंतर घोषणात्मक (अद्वितीय बाधा) बनाम स्पष्ट (अद्वितीय सूचकांक बनाएं) है - दोनों डुप्लिकेट मानों को रोकते हैं B UNIQUE index is always faster than UNIQUE constraint UNIQUE सूचकांक हमेशा UNIQUE बाधा से तेज़ होता है C UNIQUE constraint allows NULL; UNIQUE index does not अद्वितीय बाधा शून्य की अनुमति देती है; अद्वितीय सूचकांक नहीं है D UNIQUE constraint is enforced by the application; UNIQUE index by the DBMS UNIQUE constraint is enforced by the application; डीबीएमएस द्वारा अद्वितीय सूचकांक ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) In most DBMS (MySQL, PostgreSQL, SQL Server): UNIQUE constraint = UNIQUE index internally. Both prevent duplicate values (with NULL handling varying by DBMS). UNIQUE constraint is the declarative, SQL-standard way. CREATE UNIQUE INDEX is explicit and gives more control over index name, type, and storage options. व्याख्या (हिन्दी) अधिकांश DBMS (MySQL, PostgreSQL, SQL सर्वर) में: अद्वितीय बाधा = आंतरिक रूप से अद्वितीय सूचकांक। दोनों डुप्लिकेट मानों को रोकते हैं (DBMS द्वारा भिन्न-भिन्न NULL हैंडलिंग के साथ)। अद्वितीय बाधा घोषणात्मक, SQL-मानक तरीका है। क्रिएट यूनिक इंडेक्स स्पष्ट है और इंडेक्स नाम, प्रकार और भंडारण विकल्पों पर अधिक नियंत्रण देता है। 🎯 Exam Perspective DBMS ("DDL Commands" sub-topic) के इस प्रश्न को — difficulty level "Medium" कई प्रतियोगी परीक्षाओं जैसे UPSC, SSC, Banking और Police भर्ती में repeat होते देखा गया है। Concept clarity के लिए explanation section जरूर पढ़ें। 🔗 Related Questions DROP TABLE removes Which DDL command modifies column data type What is the SQL standard CREATE VIEW statement and what... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
131 Question 131 EN + हिं Easy GB What is the SQL standard CREATE VIEW statement and what properties must hold for a view to be created successfully? IN SQL मानक क्रिएट व्यू स्टेटमेंट क्या है और किसी व्यू को सफलतापूर्वक बनाने के लिए कौन से गुण होने चाहिए? A Views can be created from any SQL statement किसी भी SQL कथन से दृश्य बनाए जा सकते हैं B Views must always reference at least two base tables दृश्यों को हमेशा कम से कम दो आधार तालिकाओं का संदर्भ देना चाहिए C A view is created from a valid SELECT statement; key requirements vary by DBMS but typically: no ORDER BY in the view definition (without LIMIT/TOP), consistent column names (either from SELECT or via aliases), and the underlying tables/views must exist एक वैध चयन कथन से एक दृश्य बनाया जाता है; मुख्य आवश्यकताएँ DBMS के अनुसार अलग-अलग होती हैं, लेकिन आम तौर पर: दृश्य परिभाषा में कोई ORDER BY नहीं (बिना LIMIT/TOP), सुसंगत कॉलम नाम (या तो SELECT से या उपनाम के माध्यम से), और अंतर्निहित तालिकाएँ/दृश्य मौजूद होने चाहिए D Views can include INSERT UPDATE DELETE statements दृश्यों में INSERT UPDATE DELETE कथन शामिल हो सकते हैं ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) CREATE VIEW view_name AS SELECT col1, col2, expr AS alias FROM table WHERE condition. Requirements: unique column names (use aliases for computed columns or duplicates), no parameters (unlike table-valued functions), underlying tables must exist. ORDER BY in view is allowed only if TOP/LIMIT is used (implementation-specific). व्याख्या (हिन्दी) CREATE VIEW view_name AS SELECT col1, col2, expr AS alias FROM table WHERE condition. आवश्यकताएँ: अद्वितीय कॉलम नाम (गणना किए गए कॉलम या डुप्लिकेट के लिए उपनाम का उपयोग करें), कोई पैरामीटर नहीं (तालिका-मूल्यवान फ़ंक्शन के विपरीत), अंतर्निहित तालिकाएं मौजूद होनी चाहिए। ORDER BY in view is allowed only if TOP/LIMIT is used (implementation-specific). 🎯 Exam Perspective यह सवाल DBMS ("DDL Commands" sub-topic) category का है — difficulty level "Easy", और Railway, SSC, Banking और Defence परीक्षाओं के exam pattern में इस तरह के questions common हैं। Answer choose करने के बाद दिया गया explanation जरूर पढ़ें। 🔗 Related Questions What is CREATE TEMPORARY TABLE and what is its scope? What is the purpose of GRANT and REVOKE statements in S... DROP TABLE removes 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
132 Question 132 EN + हिं Medium GB What is the purpose of ALTER TABLE RENAME and does it affect dependent objects? IN ALTER TABLE RENAME का उद्देश्य क्या है और क्या यह निर्भर वस्तुओं को प्रभावित करता है? A ALTER TABLE old_name RENAME TO new_name changes the table name; most DBMS automatically update references in foreign key constraints but views stored procedures and application code may break - the impact depends on DBMS version and dependency management capabilities ALTER TABLE old_name RENAME TO new_name changes the table name; अधिकांश DBMS स्वचालित रूप से विदेशी कुंजी बाधाओं में संदर्भों को अपडेट करते हैं लेकिन संग्रहित प्रक्रियाओं और एप्लिकेशन कोड को तोड़ सकते हैं - प्रभाव DBMS संस्करण और निर्भरता प्रबंधन क्षमताओं पर निर्भर करता है B It temporarily aliases the table name यह अस्थायी रूप से तालिका नाम को उपनाम देता है C It creates a copy of the table with the new name यह नए नाम के साथ तालिका की एक प्रति बनाता है D It only changes the table name in the catalog यह केवल कैटलॉग में तालिका का नाम बदलता है ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) ALTER TABLE RENAME: changes table name in the system catalog. Most modern DBMS (PostgreSQL, MySQL 8.0+) update FK references automatically. BUT: views that reference the old table name may become invalid, stored procedures/functions referencing the old name break, application code using hardcoded table names must be updated. व्याख्या (हिन्दी) तालिका का नाम बदलें: सिस्टम कैटलॉग में तालिका का नाम बदलता है। Most modern DBMS (PostgreSQL, MySQL 8.0+) update FK references automatically. लेकिन: पुराने तालिका नाम को संदर्भित करने वाले दृश्य अमान्य हो सकते हैं, पुराने नाम को संदर्भित करने वाली संग्रहीत कार्यविधियाँ/फ़ंक्शन, हार्डकोडेड तालिका नामों का उपयोग करने वाले एप्लिकेशन कोड को अद्यतन किया जाना चाहिए। 🎯 Exam Perspective यह प्रश्न DBMS ("DDL Commands" sub-topic) की तैयारी करने वाले अभ्यर्थियों के लिए उपयोगी है — difficulty level "Medium"। इस तरह के प्रश्न अक्सर SSC, Railway, Banking और State PCS जैसी परीक्षाओं में पूछे जाते रहे हैं, इसलिए concept और explanation दोनों को ध्यान से समझें, सिर्फ उत्तर याद न करें। 🔗 Related Questions What does INHERITS clause do in PostgreSQL CREATE TABLE... What is the effect of DROP COLUMN on a table with index... What is CREATE TEMPORARY TABLE and what is its scope? 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
133 Question 133 EN + हिं Medium GB What is the SQL COMMENT statement and how is metadata typically managed in production databases? IN SQL COMMENT कथन क्या है और मेटाडेटा को आमतौर पर उत्पादन डेटाबेस में कैसे प्रबंधित किया जाता है? A Comments replace actual column/table names टिप्पणियाँ वास्तविक कॉलम/तालिका नामों का स्थान ले लेती हैं B COMMENT ON is only available in Oracle databases COMMENT ON केवल Oracle डेटाबेस में उपलब्ध है C Comments are only in SQL code not stored in the database टिप्पणियाँ केवल SQL कोड में हैं, डेटाबेस में संग्रहीत नहीं हैं D COMMENT ON TABLE/COLUMN/INDEX stores metadata descriptions in the system catalog (standard SQL); in production databases metadata management also includes: documentation in data catalogs (Apache Atlas, Collibra), ERD tools, and data dictionaries maintained alongside the schema टेबल/कॉलम/इंडेक्स पर टिप्पणी सिस्टम कैटलॉग (मानक एसक्यूएल) में मेटाडेटा विवरण संग्रहीत करती है; उत्पादन डेटाबेस में मेटाडेटा प्रबंधन में यह भी शामिल है: डेटा कैटलॉग में दस्तावेज़ीकरण (अपाचे एटलस, कोलिब्रा), ईआरडी उपकरण, और स्कीमा के साथ बनाए गए डेटा शब्दकोश ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) COMMENT ON TABLE emp IS Employee master table; COMMENT ON COLUMN emp.salary IS Annual salary in USD (not including bonuses). Stored in system catalog (information_schema.column_comments in MySQL, pg_description in PostgreSQL). Production metadata management: data catalog tools track lineage, ownership, PII classification, business definitions. व्याख्या (हिन्दी) टेबल एम्प पर टिप्पणी कर्मचारी मास्टर टेबल है; कॉलम पर टिप्पणी emp.salary USD में वार्षिक वेतन है (बोनस शामिल नहीं)। सिस्टम कैटलॉग में संग्रहीत (MySQL में information_schema.column_comments, PostgreSQL में pg_description)। उत्पादन मेटाडेटा प्रबंधन: डेटा कैटलॉग उपकरण वंश, स्वामित्व, पीआईआई वर्गीकरण, व्यावसायिक परिभाषाओं को ट्रैक करते हैं। 🎯 Exam Perspective DBMS ("DDL Commands" sub-topic) से जुड़ा यह सवाल — difficulty level "Medium" उन students के लिए काम का है जो SSC CGL, IBPS, RRB और State-level परीक्षाओं की तैयारी कर रहे हैं। बेहतर होगा कि explanation पढ़कर concept clear करें, ताकि exam में similar प्रश्न आने पर confusion न हो। 🔗 Related Questions What is the difference between a UNIQUE constraint and... In DDL what is the difference between CONSTRAINT constr... What is CREATE TEMPORARY TABLE and what is its scope? 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
134 Question 134 EN + हिं Medium GB DROP TABLE removes IN ड्रॉप टेबल हटाता है A Only the data केवल डेटा B Only indexes केवल अनुक्रमणिका C Only constraints केवल बाधाएँ D Table structure, all data, indexes, and constraints permanently तालिका संरचना, सभी डेटा, अनुक्रमणिका और बाधाएँ स्थायी रूप से ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) DROP TABLE permanently removes table definition AND all associated data, indexes, constraints. व्याख्या (हिन्दी) ड्रॉप टेबल स्थायी रूप से टेबल परिभाषा और सभी संबंधित डेटा, इंडेक्स, बाधाओं को हटा देता है। 🎯 Exam Perspective Railway, SSC, Banking और Defence परीक्षाओं जैसी परीक्षाओं में DBMS ("DDL Commands" sub-topic) से सवाल अक्सर पूछे जाते हैं — difficulty level "Medium"। इसलिए सिर्फ answer रटने के बजाय, नीचे दी गई explanation को ध्यान से पढ़ें और concept समझें। 🔗 Related Questions What is the purpose of ALTER TABLE RENAME and does it a... What is online schema change (OSC) and why is it needed... What is the purpose of CREATE ASSERTION statement in st... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)
135 Question 135 EN + हिं Medium GB Which DDL command modifies column data type IN कौन सा DDL कमांड कॉलम डेटा प्रकार को संशोधित करता है A ALTER TABLE t ADD col तालिका बदलें और कॉलम जोड़ें B ALTER TABLE t DROP col तालिका बदलें टी ड्रॉप कर्नल C ALTER TABLE t DROP CONSTRAINT तालिका बदलें और बाधा हटाएं D ALTER TABLE t MODIFY/ALTER COLUMN col newtype तालिका बदलें और कॉलम को नया प्रकार में संशोधित/बदलें ✅ Correct Answer: 💡 Explanation / व्याख्या Explanation (English) ALTER TABLE t MODIFY COLUMN col newtype (MySQL) / ALTER COLUMN (SQL Server) changes column definition. व्याख्या (हिन्दी) ALTER TABLE t Modify COLUMN col newtype (MySQL) / ALTER COLUMN (SQL Server) कॉलम परिभाषा को बदलता है। 🎯 Exam Perspective अगर आप SSC, Railway, Banking और State PCS की तैयारी कर रहे हैं, तो DBMS ("DDL Commands" sub-topic) का यह topic आपके लिए महत्वपूर्ण है — difficulty level "Medium"। Exam में accuracy बढ़ाने के लिए हर सवाल की explanation जरूर पढ़ें। 🔗 Related Questions What is the difference between a UNIQUE constraint and... What is CREATE TEMPORARY TABLE and what is its scope? What is the purpose of CREATE ASSERTION statement in st... 📚 Related Topic Introduction to DBMS (639) Database Architecture (135) Data Models (138)