91
GB
What is the NOCOPY hint in PL/SQL parameter passing and when should it be used?
IN
PL/SQL पैरामीटर पासिंग में NOCOPY संकेत क्या है और इसका उपयोग कब किया जाना चाहिए?
A
A hint that prevents trigger copying of row values
एक संकेत जो पंक्ति मानों की ट्रिगर प्रतिलिपि को रोकता है
B
A hint to avoid copying data to disk
डिस्क पर डेटा कॉपी करने से बचने का संकेत
C
A PL/SQL performance hint that passes OUT/IN OUT parameters by reference instead of by default copy (pass by value) avoiding expensive copying of large collections/records; should be used when: parameters are large (LOBs big collections) and the overhead of copying would be significant
एक पीएल/एसक्यूएल प्रदर्शन संकेत जो बड़े संग्रह/अभिलेखों की महंगी प्रतिलिपि से बचने के लिए डिफ़ॉल्ट प्रतिलिपि (मूल्य से पास) के बजाय संदर्भ द्वारा आउट/इन आउट पैरामीटर पास करता है; इसका उपयोग तब किया जाना चाहिए जब: पैरामीटर बड़े हों (एलओबी बड़े संग्रह) और प्रतिलिपि बनाने का ओवरहेड महत्वपूर्ण होगा
D
A hint to avoid copying package variable values
पैकेज वैरिएबल मानों की प्रतिलिपि बनाने से बचने का संकेत
✅ Correct Answer:
💡 Explanation / व्याख्या
Explanation (English)
Default OUT param: entire collection/record copied in at start and copied out on return (expensive for large data). NOCOPY hint: passes reference directly (no copy). PROCEDURE p(p_data IN OUT NOCOPY large_collection_type). Warning: if procedure raises exception with NOCOPY parameter may be partially modified (no rollback of param changes). Trade-off: performance vs. atomicity.
व्याख्या (हिन्दी)
डिफ़ॉल्ट आउट पैरामीटर: संपूर्ण संग्रह/रिकॉर्ड प्रारंभ में कॉपी किया गया और वापसी पर कॉपी किया गया (बड़े डेटा के लिए महंगा)। NOCOPY संकेत: सीधे संदर्भ पास करता है (कोई प्रतिलिपि नहीं)। प्रक्रिया पी(पी_डेटा इन आउट नोकॉपी लार्ज_कलेक्शन_टाइप)। चेतावनी: यदि प्रक्रिया NOCOPY पैरामीटर के साथ अपवाद उठाती है तो आंशिक रूप से संशोधित किया जा सकता है (परम परिवर्तनों का कोई रोलबैक नहीं)। ट्रेड-ऑफ़: प्रदर्शन बनाम परमाणुता।