tag:blogger.com,1999:blog-21388556736527778812024-03-13T17:52:52.923+05:30MeansOFminEMy Stuffs and InformationsUnknownnoreply@blogger.comBlogger15125tag:blogger.com,1999:blog-2138855673652777881.post-14578651009168196552011-06-05T22:56:00.000+05:302011-06-05T22:56:09.438+05:30ORACLE: Backup and Recovery<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-OufDeaEo6Uo/Teu7cXejrKI/AAAAAAAAAbg/95scfzeykeU/s1600/oracle%2Bdatabase.jpg" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="320" src="http://2.bp.blogspot.com/-OufDeaEo6Uo/Teu7cXejrKI/AAAAAAAAAbg/95scfzeykeU/s320/oracle%2Bdatabase.jpg" width="320" /></a></div>
<br />
<center style="font-family: inherit;"></center><center style="font-family: inherit;"><hr style="margin-left: 0px; margin-right: 0px;" />
<span style="font-size: small;"> </span><span style="font-size: small;"><span style="font-size: large;"> <i style="color: #3d85c6;"><b>ORACLE: Backup and Recovery</b></i></span> </span><hr style="margin-left: 0px; margin-right: 0px;" />
</center><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> To ensure safe operation of the database and prompt failover is needed to plan a backup strategy, <i>backup</i> and recovery, <i>recovery,</i> and it's useless to think that we are safe from such circumstances, and that's not I can happen to me.
And the first step to take is to define the fundamental characteristics
of the implementation, because we're going to get bad goals if they
know or are undefined. The second step is to establish plans for backup and recovery that will enable us to secure the objectives.</span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span></div>
<span style="font-family: inherit; font-size: small;"></span><br />
<hr style="font-family: inherit; margin-left: 0px; margin-right: 0px;" />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="1"></a> <b>1 Introduction to <i>Backup</i> and Recovery</b> </span><br />
<hr style="font-family: inherit; margin-left: 0px; margin-right: 0px;" />
<span style="font-family: inherit; font-size: small;">Planning and testing <i>backup</i> procedures of the system is the only guarantee that exists against system crashes, the OS, software or any other circumstances.</span><br />
<div style="font-family: inherit; text-align: justify;">
</div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The causes of error in a DB system can be grouped into the following categories: </span></div>
<ul style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Physical </span></li>
<ul><span style="font-size: small;"> are caused by hardware failures such as disk or CPU.</span></ul>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Design </span></li>
<ul><span style="font-size: small;"> are holes in the software, either OS or DBMS.</span></ul>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Operating </span></li>
<ul><span style="font-size: small;"> are caused by human intervention, due to failure of the DBA, inappropriate or wrong approach configurations of <i>backup</i> procedures.</span></ul>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Environment </span></li>
<ul><span style="font-size: small;"> such as natural disasters, power failures, overheating.</span></ul>
</ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;">
Of all these possibilities, the DBA can only influence and predict
malfunctions, since the rest is generally not within their
responsibilities and capabilities. </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;">
Given the complexity of current systems and the increasingly critical
needs in the availability of systems, where a drop BD can cause millions
in losses, may be worth considering the hardware security mechanisms
and redundancy that technology gives us: </span></div>
<ul style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> UPS or uninterrupted power supplies, </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Disk <i>mirroring</i> or RAID technology, </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Duplicate components, </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Redundant systems. </span></li>
</ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> One of the most important decisions that a DBA must make is whether to start the database in ARCHIVELOG mode or not. This decision has its advantages and disadvantages:</span> </div>
<ul style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Advantages: </span></li>
<ul>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Although lost data files, you can always recover the database with an old copy of data files and archived <i>redo log</i> files. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> You can make hot <i>backups.</i> </span></li>
</ul>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Disadvantages: </span></li>
<ul>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> It will take more disk space. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> The work of the DBA is increased by having to determine the fate of the <i>redo log</i> archiving. </span></li>
</ul>
</ul>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="1.1"></a> <b><i>Backup</i> 1.1 Introduction</b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The <i>backups</i> can be classified into physical and logical. Physicists are performed when copying the files that support BD. These include OS <i>backups,</i> cold <i>backups</i> and hot <i>backups.</i></span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The only logical <i>backups</i> extract data from tables using SQL commands and performed with the use export / import. </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>OS <i>Backups</i></b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> </span><span style="font-size: small;"> This type of <i>backup</i> is the easiest to implement, although time consuming and makes it inaccessible to the system as it performs. Seize the OS to store <i>backup</i> files also all of the database. The steps in this type of <i>backup</i> are:</span> <br />
<ol>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Stop the BD and SO </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Starting in superuser mode. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Back up all files in the filesystem </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Start the system in normal mode and then BD. </span></li>
</ol>
</ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b><i>Backups</i> of the Cold BD</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> The mean cold <i>backups</i> the database to stop in normal mode and copy all the files on which it sits. Before stopping the database must also stop all applications that are working with the BD. Once the copy of the files, the database can be restarted.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>DB <i>Backups</i> Hot</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> The hot <i>backup</i> is performed while the database is open and running in ARCHIVELOG mode. Care should be taken to do when the load of the database is small. This type of <i>backup</i> is to copy all files relating to a particular <i>tablespace,</i> archived <i>redo log</i> files and control files. This for each <i>tablespace</i> of the database.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Logical <i>Backups</i> with <i>Export / Import</i></b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> These utilities allow the DBA to back certain objects from the DB, and restore or move a DB to another. These tools use SQL commands to get the contents of the objects and write / read files</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Once you have planned <i>backup</i> strategy and has been tested, it is automated to facilitate compliance. </span></div>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="1.2"></a> <b>1.2 Presentation of Recovery</b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;">
Oracle provides several ways to recover a failure in the database, and
it is important that the DBA know how each one of them to determine when
to be used. </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;">
One of the major responsibilities of the DBA is to have the database
ready, and prepare for the possibility that a failure occurs. So, after a failure, the DBA can recover the database in the shortest time possible. Recovery processes depend on the type of error and structures affected.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Thus, the types of errors that can occur are: </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>User Errors</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> Such as a user deletes a row or deleting a table. These errors can be solved by importing a table from a previous logical copy.
If there is no logical copy, you can recover the database in an
auxiliary instance, export the table in question from the auxiliary
instance in the instance and import operations.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Sentencing judgments</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> Defined as the inability of the Oracle DBMS running any SQL statement. An example of this occurs when you try a selection from a table that does not exist. These faults are automatically retrieved by a <i>rollback</i> of the transaction containing the statement failed. The user will need to re-run the transaction again when you've fixed the cause of the problem.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Process failures</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> It is an abnormal termination of a process. If the process was a process of user, an application server or the <i>PMON</i> fee recovery process. If the process was one of those <i>background,</i> the agency should be stopped and restarted, a process during which the fall is recovered by performing a <i>forward roll</i> and a <i>rollback</i> of uncommitted transactions.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Network Failures</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> Sometimes network failures of process failures occur, they are treated by the <i>PMON.</i> If the network error is involved a distributed transaction, once the connection is reestablished, the <i>RECO</i> process automatically resolves conflicts.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Instance failures</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> Failures may be due to physical or software design that make a <i>background</i> process and the body falls with it. Recovery is automatic when you get up the database, taking more or less time in recovery.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>System Failures</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;">
They are the most dangerous faults, not only because you can lose data,
but because it takes longer to recover than the other faults. In addition, much depends on the experience of the DBA to lift the BD quickly and ordered (or most) of data.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> There are three types of Oracle recovery: a block level of <i>thread</i> and physics. </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Recovery blocks</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> Recovery mechanism is simple and is done automatically. Occurs when a process dies just as he is changing a block, and uses the online <i>redo log</i> records to reconstruct the block and write to disk.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Recovery <i>threads</i></b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> Oracle is done automatically when an instance dies he discovers that keeping open a <i>thread,</i> then restores the changed data blocks that were in the <i>cache</i> of the dead body, and closing the <i>thread</i> that was open. The recovery is performed automatically either when the BD is closed.</span></ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Physical recovery</b> </span></div>
<ul style="font-family: inherit; text-align: justify;"><span style="font-size: small;"> Is in response to a RECOVER command. It is used to convert the current <i>backup</i> files, or to restore the changes that were lost when a data file was put <i>offline</i> without a <i>checkpoint,</i> applying the archived <i>redo log</i> file and online.</span></ul>
<hr style="font-family: inherit; margin-left: 0px; margin-right: 0px;" />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="2"></a> <b>2 <i>Backup</i> Principles</b> </span><br />
<hr style="font-family: inherit; margin-left: 0px; margin-right: 0px;" />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> A valid <i>backup</i> is a copy of the database information necessary to rebuild the database from an unusable state thereof. Normally, if the <i>backup</i> strategy is based on the copy of data files and archived <i>redo log</i> files, you should have copies of data files, the control files, <i>redo log</i> files of assets and also the archived. If you lose one of the archived <i>redo log</i> files says it has a hole in the sequence of files. This invalidates the <i>backup,</i> but enables the BD to be carried to the top of the hole by an incomplete recovery.</span> </div>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="2.1"></a> <b>2.1 Design of the BD and <i>Backup</i> Basic Rules</b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;">
First of all, it is very important to understand certain rules that
determine the location of files and other considerations that affect the
<i>backup</i> scheme: </span></div>
<ul style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> It is advisable to archive the <i>redo log</i> files on disk and then copy to tape, but always in a different drive that supports data files and <i>redo log</i> assets. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Copies files should not be in the same device as the original. Not always have to pass the copies to tape, because if left in accelerating recovery disk. Also, if copies are copied to tape and kept in the disk, it can survive several device failures.</span> </li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> It should keep multiple copies of control files, placed on different disks with different drivers. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> The online <i>redo log</i> files should be multiplexed with a minimum of 2 members per group, each member residing on a different disk. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Whenever the structure of the BD changes due to the inclusion, deletion or renaming a data file or <i>redo log,</i> copy the control file by storing the structure of the database. In addition, every file added must also be copied. The control file can be copied while the database is open with the following command: </span><pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">SVRMGR> alter database backup controlfile to 'target';</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</li>
</ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Given the above rules, the following can be considered an example of a <i>backup</i> strategy: </span></div>
<ol style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Enable ARCHIVELOG mode. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Make a <i>backup</i> at least once a week if the database can be stopped. Otherwise, hot <i>backups</i> every day.</span> </li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Copy all archived <i>redo log</i> files every four hours. The size and number of them depend on the rate of transactions.</span> </li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Make a weekly export of the database in restricted mode. </span></li>
</ol>
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="2.2"></a> <b>2.2 Physical <i>Backups</i></b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Physical <i>backups</i> are physically copied those files from the database. There are two options: cold and hot. It is said that the cold <i>backup</i> when the files are copied to the database is stopped. Hot is when copying files with the database open and running.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Cold <i>Backup</i></b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The first step is to stop the BD with normal shutdown. If the database must be stopped with immediate or abort is rebooted with the RESTRICT mode and stop mode back to normal. After copying the datafiles, the <i>redo log</i> and control, plus the archived <i>redo log</i> and not yet copied.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> A good idea is to automate this process with appropriate <i>scripts,</i> so do not forget to copy any files. </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Since this type of <i>backup</i> is a copy of the database files if they contain some kind of corruption, will push the backup without detecting it. Therefore it is important to check the backups.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Hot <i>Backup</i></b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> If the implementation of BD requires the same 24-hour availability. a day, 7 days a week can not be cold <i>backups.</i> To perform a hot <i>backup</i> should work with the database in ARCHIVELOG mode. The hot <i>backup</i> procedure is quite similar to the cold. There are two additional commands: begin backup and end before the end of the <i>backup</i> backup. For example, before and after making a <i>backup</i> of <i>tablespace</i> users should execute the statements:</span> </div>
<pre style="font-family: inherit;"><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">SVRMGR> alter tablespace users begin backup;</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">SVRMGR> alter tablespace users end backup;</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> And allowed the cold <i>backup</i> to back all the time BD, hot <i>backups</i> on the treatment unit is the <i>tablespace.</i> The hot <i>backup</i> involves copying the data files (and <i>tablespaces),</i> the current control file and all archived <i>redo log</i> files created during the <i>backup.</i> It will also require all archived <i>redo log</i> files after the hot <i>backup</i> to make a full recovery.</span> </div>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="2.3"></a> <b>2.3 Logical <i>Backups</i></b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> This type of <i>backup</i> copy the contents of the database without storing the physical location of data. Performed with the <i>export</i> tool to copy the data and the definition of BD in a file in Oracle internal format.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> To make a <i>export</i> the database must be open. <i>Export</i> ensures consistency in the table, but not between tables. If consistency is required between all tables in the database then you should not make any transactions during the <i>export</i> process. This can be achieved if you open the database in restricted mode.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Among the advantages of carrying out an <i>export</i> are the following: </span></div>
<ul style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> It can detect corruption in data blocks, as the <i>export</i> process will fail. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Protects user faults, for example if you delete a row or an entire table by mistake is easily retrieved by an <i>import.</i> </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> You can export the data to determine with great flexibility. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> <i>Exports</i> can be made full, incremental and cumulative. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Arisen I deem to <i>export backups</i> are portable and serve as an interchange format between BDs and data between machines. </span></li>
</ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> One of the disadvantages of <i>export</i> Logical <i>backups</i> is that they are much slower than physical <i>backups.</i> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> <b><i> </i></b></span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"><b><i>Export</i> parameters</b></span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"><b> </b> </span></div>
<br />
<center style="font-family: inherit;"><table border="1" style="margin-left: 0px; margin-right: 0px; text-align: left;"><tbody>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> <i><b>Parameter</b></i> </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> <i><b>Default</b></i> </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> <i><b>Description</b></i> </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> USERID </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> username / password of the user performing the <i>export.</i> </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> BUFFER </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> OS dependent </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> The size in bytes of the buffer used. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> FILE </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> expdat.dmp </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> destination file name. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> GRANTS </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether the rights are also exported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> INDEXES </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether the indices are also exported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> ROWS </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicating whether they are also exported rows of tables, or just the table definitions. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> CONSTRAINTS </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether the restrictions are also exported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> COMPRESS </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether compressed mode is exported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> FULL </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> No </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether to export the whole DB. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> OWNER </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> current user </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> a list of users whose objects are to be exported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> TABLES </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> the list of tables to export. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> RecordLength </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> OS dependent </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> the length in bytes of the log file. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> INCTYPE </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> the type of incremental <i>export.</i> </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> RECORD </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether to record the incremental <i>export</i> tables and SYS.INCEXP SYS.INCVID. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> PARFILE </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> parameter file. </span></td></tr>
</tbody></table>
</center><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> <b><i> </i></b></span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"><b><i>Export</i> Modes</b></span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"><b> </b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> There are three ways to make a data export: </span></div>
<dl style="font-family: inherit; text-align: justify;">
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> Table Mode </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;">
Exporting table definitions, data, rights of the owner, owner's rates,
restrictions on the table and triggers associated with the table. </span></dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> User Mode </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> Exported all over Table mode <i>clusters,</i> BD links, views, private synonyms, sequences, procedures, etc. user.</span> </dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> Whole BD mode </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> Besides all the User, export roles, all synonyms, system privileges, the definitions of the <i>tablespaces, tablespace</i> quotas in the definitions of <i>rollback</i> segments, the system auditing options, all triggers and profiles. </span></dd></dl>
<span style="font-family: inherit; font-size: small;"> The whole way BD can be divided into three cases: Full, cumulative and incremental. The latter two take less time than the complete, and can export only the changes in the data and definitions. </span>
<br />
<dl style="font-family: inherit; text-align: justify;">
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> Full </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> Export all tables in the database and initializes the incremental export information from each table. After a full export are not needed files cumulative and incremental exports of the previous BD. </span><br />
<pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">$ Exp userid = system / manager full = y constraints inctype = complete = Y</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">file = full_export_filename</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> Cumulative </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;">
Exports only tables that have been modified or created since the last
cumulative or complete export and export records the details for each
exported table. After a cumulative export are not needed incremental export files of previous BD. </span><br />
<pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">$ Exp userid = system / manager full = y inctype = cumulative constraints = Y</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">file = cumulative_export_filename</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> Incremental </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;">
Exports all tables modified or created since the last export
Incremental, Cumulative or complete, and records the details of export
for each exported table.
Are interesting in environments where many tables remain static for
long periods of time, while others vary and need to be copied. This type of operation is useful when you need to quickly recover accidentally deleted a table. </span><br />
<pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">$ Exp userid = system / manager full = y inctype = incremental constraints = Y</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">file = incremental_export_filename</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</dd></dl>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;">
Export policy can be the following: perform a full export on day 1 (ie
Sunday), then do incremental exports the rest of the week. This Monday to Saturday only export those tables will be exported to save time in the process.</span> </div>
<hr style="font-family: inherit; margin-left: 0px; margin-right: 0px;" />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="3"></a> <b>3 Principles of Recovery</b> </span><br />
<hr style="font-family: inherit; margin-left: 0px; margin-right: 0px;" />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> To understand the principles of recovery, you need to understand the underlying data structures used in recovery. </span></div>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="3.1"></a> <b>3.1 Definitions and Concepts</b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <i>Redo log</i> files contain the changes made to the database. Should present some concepts related to them.</span> </div>
<dl style="font-family: inherit; text-align: justify;">
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> Change Vector </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> describes a simple change in a data block DB. Among other data, contains the version number, transaction code, and address of the block in question.</span> </dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> <i>Redo log</i> record </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> is a set of change vectors describing an atomic change on the database. The transaction is also the unit of recovery.</span> </dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> Evolution of <i>Redo log</i> per day </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> can be calculated by running the command archive log list on two consecutive days and calculating the difference of the sequence number of <i>redo log</i> files, multiplied by the size of a <i>redo log</i> file: </span><br />
<pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">SVRMGR> archive log list;</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Database log mode No Archive Mode</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Automatic archival Disabled</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Archive destination / opt / app / oracle / admin / demo / arch / arch.log</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Oldest online log sequence 3</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Current log sequence 5</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> <i>System Change Number,</i> SCN </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> is data that defines the committed version of the database at this point in time. When a transaction is confirmed, is assigned a SCN that identifies it uniquely. <i>Redo log</i> files are marked with two SCN. When you open a new <i>redo log</i> file is marked with an SCN, <i>SCN low,</i> which is one more than the greater of the previous SNA <i>redo log</i> file, and its <i>high SCN</i> is set to infinity. The SCN also associated with control file, because when for a BD, a <i>tablespace</i> or data file is stored for each data file the <i>stop SCN</i> in control file.</span> </dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> <i>Redo</i> change <i>log</i> </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> is the process by which it ceases to use a <i>redo log</i> file and LGWR van to the next available <i>redo log</i> file. It can be done with the command alter system switch logfile;.</span> </dd>
<dt><span style="font-size: small;"> </span><span style="font-size: small;"> <i>Checkpoints</i> </span></dt>
<dd><span style="font-size: small;"> </span><span style="font-size: small;"> are automatically activated during normal operation of the instance, but can be activated manually using the alter system command alter system checkpoint local or global checkpoint depending on whether we refer to the instance in which we, or you want to affect all active instances , respectively. Each implies a <i>checkpoint</i> SCN, and Oracle ensures that all changes with an SCN lower than the given <i>checkpoint</i> are written to disk.</span> </dd></dl>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="3.2"></a> <b>3.2 Methods of Recovery</b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> There are several methods of recovery, but all are based on the application of <i>redo log</i> records. </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Application of <i>Redo Log</i></b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> When a BD is started with the startup command, the database passes <i>nomount</i> states, <i>mount</i> and <i>open.</i> In this third state, it verifies that you can open all <i>log</i> files and data.
If the database is started for the first time after a fall, will
necessitate a recovery that consists of two steps: moving forward using
the database <i>redo log</i> records, to undo the uncommitted transactions.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Each data file has in his head made the last <i>checkpoint</i> and the control file also holds the account. The <i>checkpoint</i> has included the SCN. The SCN is known as boot file. Associated with each data file control file has the final SNA, as initially infinite. The start SCN is incremented with each <i>checkpoint.</i></span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;">
When the database is in normal mode or to immediately stop equals the
SCN for each data file to the SCN stored in each data file. When you open the database again there are two checks. The first is to see if the counter of <i>checkpoints</i> in the header of data files match the corresponding control file. If so, it compares the start SCN of each data file with the final SCN stored in control file. If they are equal no recovery is needed in this data file. As part of the opening is set to infinity, the final SNA data to that file.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> If the database is stopped with <i>abort</i> mode was not implemented and the <i>checkpoint</i> SCN of the end for the data file is to infinity. Thus, during the database opens, and assuming that the counter matches <i>checkpoints,</i> comparing SCN start and end, as the latter is infinite recovery Shall applying the changes stored in the online <i>redo log</i> files to move the BD, and <i>roll back</i> logs of <i>rollback</i> segments to undo uncommitted transactions.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> If after stopping the database to replace a data file for your backup, to start the Oracle BD meter detects that the <i>checkpoints</i> of the data file does not match the one stored in the control file. Thus, we have to dip into archived <i>redo log</i> files, starting with one whose sequence number appears in the data file header.</span> </div>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="3.3"></a> <b>Physical Recovery 3.3</b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Using a <i>backup</i> copy of data files always need a physical recovery. It is also the case when a data file gets <i>offline</i> without a <i>checkpoint.</i></span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Oracle detects that physical recovery is needed when the timer <i>checkpoints</i> of the data file header does not match the corresponding counter control file <i>checkpoint.</i> Then it becomes necessary to recover command. Recovery begins in the SCN under data files recovery, applying <i>redo log</i> records from him, and stopping on the final SNA greatest of all data files.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> There are three options to make a physical recovery. The first is a recovery of BD where BD is restored whole. The second is a <i>tablespace</i> recovery where, as part of the database is open, you can retrieve a specific <i>tablespace.</i> This means that all files will be recovered associated with the <i>tablespace</i> data. The third type is the recovery of a specific data file while the rest of the database is open.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Use Requirements for Physical Recovery</b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The first condition to be able to recover physically put a DB is that it is being used in ARCHIVELOG mode. Otherwise, a full recovery may not be possible. By working with the BD NOARCHIVELOG
mode, and makes a weekly copy of the database files, you should be
prepared to lose, at worst, the work of the last week if a failure
occurs. Since the <i>redo log</i> files contain a hole and could not move the database to pre intant failure. In this case the only way to rebuild the database is done from a full <i>export,</i> re-creating the schema of the database and importing all the data.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>DB recovery</b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The BD must be mounted but not open. The recovery command is:</span> </div>
<pre style="font-family: inherit;"><span style="font-size: small;"> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">RECOVER [AUTOMATIC] [FROM 'location'] [BD]</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">[UNTIL CANCEL]</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">[UNTIL TIME date]</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">[UNTIL CHANGE integer]</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">[USING BACKUP CONTROLFILE]</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The options in brackets are optional: </span></div>
<ul style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> AUTOMATIC makes recovery is done automatically without prompting the DBA for the name of the <i>redo log</i> files. Can also be used for this purpose the set command Autorecovery on / off. <i>Redo log</i> files should be at the location specified in LOG_ARCHIVE_DEST and format of the filenames should be set at LOG_ARCHIVE_FORMAT.</span> </li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> FROM is used to determine the location where the <i>redo log</i> files, if different from fixed LOG_ARCHIVE_DEST. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> UNTIL serves to indicate that you want to perform incomplete recovery, which means losing data. Only give when they are lost or archived <i>redo log</i> file control. When you have made an incomplete recovery of BD should be opened with the command alter database open RESETLOGS, resulting in the <i>redo log</i> applied not ever to be applied and initialized the sequence of <i>redo log</i> file control. There are three options to stop the recovery: </span><ul>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> UNTIL CANCEL to retrieve a <i>redo log</i> at a time, stopping when you type CANCEL. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> TIME UNTIL recovery up to a given instant in a <i>redo log</i> file </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> CHANGE UNTIL recovery up to a given SCN. </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> USING BACKUP CONTROLFILE using a backup control file to govern the recovery. </span></li>
</ul>
</li>
</ul>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Recover a <i>tablespace</i></b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The BD should be open, but to recover the <i>tablespace offline.</i> The recovery command is:</span> </div>
<pre style="font-family: inherit;"><span style="font-size: small;"> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">RECOVER [AUTOMATIC] [FROM 'location']</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">Nombre_tablespace TABLESPACE [, nombre_tablespace]</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Recovering a Data File</b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> The BD should be open or closed, depending on the file to retrieve. If the file to retrieve is a user <i>tablespace</i> the database can be open, but with the file to recover <i>offline.</i> If the file is the SYSTEM <i>tablespace</i> the database must be closed, since there can be open with SYSTEM files <i>offline.</i> The recovery command is:</span> </div>
<pre style="font-family: inherit;"><span style="font-size: small;"> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">RECOVER [AUTOMATIC] [FROM 'location']</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> <span style="color: #737b8c;">DATAFILE filename [, filename]</span> </span><span style="color: #737b8c; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b>Creating a Control File</b> </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> If the control file is damaged and lost can use a backup of the same or create a new one. The command to create a new control file CREATE CONTROLFILE is. This command can be executed only with the BD <i>nomount</i> state. The command execution produces a new control file and the automatic assembly of the database.</span> </div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> An interesting command which helps to maintain safe control files is as follows: </span></div>
<pre style="font-family: inherit;"><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">SVRMGR> alter database backup controlfile to trace;</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> it produces a <i>script</i> that can be used to generate a new control file and recover the database, if necessary. The trace file generated is as follows:</span> </div>
<pre style="font-family: inherit;"><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Dump file / opt/app/oracle/admin/demo/udump/demo_ora_515.trc</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Oracle7 Server Release 7.3.2.3.0 - Production Release</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">With the Distributed, replication and Spatial Data options</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">PL / SQL Release 2.3.2.3.0 - Production</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">ORACLE_HOME = / opt/app/oracle/product/7.3.2</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">System name: SunOS</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Node name: cartan</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Release: 5.5</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Version: Generic</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Machine: sun4m</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Instance name: demo</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Redo thread mounted by this instance: 1</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Oracle process number: 7</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Unix process pid: 515, image: oracledemo</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Fri May 15 11:41:19 1998</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">Fri May 15 11:41:19 1998</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">*** SESSION ID: (6.2035) 1998.05.15.11.41.19.000</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># The Following commands will create a new control file and use it</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># To open the database.</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># No data log history Other Than Will Be Lost.</span> <span style="color: green;">Additional logs May</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># Be required for media recovery of offline data files.</span> <span style="color: green;">Use this</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># Only if the current version of all online logs Are available.</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">STARTUP NOMOUNT</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">CREATE CONTROLFILE REUSE DATABASE "DEMO" NORESETLOGS NOARCHIVELOG</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">MAXLOGFILES 16</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">MAXLOGMEMBERS 2</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">MAXDATAFILES 30</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">MaxInstance 1</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">MAXLOGHISTORY 100</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">LOGFILE</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">GROUP 1 '/ export/home/oradata/demo/redodemo01.log' SIZE 2M</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">GROUP 2 '/ export/home/oradata/demo/redodemo02.log' SIZE 2M</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">GROUP 3 '/ export/home/oradata/demo/redodemo03.log' SIZE 2M</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">DATAFILE</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">'/ Export/home/oradata/demo/system01.dbf'</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">'/ Export/home/oradata/demo/rbs01.dbf'</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">'/ Export/home/oradata/demo/rbs02.dbf'</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">'/ Export/home/oradata/demo/rbs03.dbf'</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">'/ Export/home/oradata/demo/temp01.dbf'</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">'/ Export/home/oradata/demo/tools01.dbf'</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">'/ Export/home/oradata/demo/users01.dbf'</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">;</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># Recovery is required if Are Any of the datafiles restored backups,</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># Or if the last shutdown Immediate or not was normal.</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">RECOVER DATABASE</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;"># Database Be Opened Normally dog now.</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">ALTER DATABASE OPEN;</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
<br />
<span style="font-family: inherit; font-size: small;"><a href="http://www.blogger.com/post-create.g?blogID=2138855673652777881" name="3.4"></a> <b>3.4 Recovery Logic</b> </span><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> Oracle <i>import</i> tool available to restore data from a BD from the results of an <i>export</i> file. <i>Import</i> reads data from export files and runs the statements that store creating tables and filling them with data. </span></div>
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> <b><i>Import</i> Parameters</b> </span></div>
<br />
<center style="font-family: inherit;"><table border="1" style="margin-left: 0px; margin-right: 0px; text-align: left;"><tbody>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> <i><b>Parameter</b></i> </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> <i><b>Default</b></i> </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> <i><b>Description</b></i> </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> USERID </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> username / password of the user performing the <i>import.</i> </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> BUFFER </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> OS dependent </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> The size in bytes of the buffer used. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> FILE </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> expdat.dmp </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> the name of the export file to import. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> SHOW </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> No </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Whether to show the contents of the export file, regardless of any data. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> IGNORE </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether to ignore errors that occur when you import an object that already exists in the database. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> GRANTS </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether the rights are also imported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> INDEXES </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether the indices are also imported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> ROWS </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Yes </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> matter also indicates whether the rows of tables. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> FULL </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> No </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether to import the entire file. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> Fromuser </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> a list of users whose objects are exported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> TOUS </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> Indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> a list of users in whose name the objects are imported. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> TABLES </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> the list of tables to import. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> RecordLength </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> OS dependent </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> the length in bytes of the log file. </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> INCTYPE </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> incremental <i>import</i> type (SYSTEM or RESTORE). </span></td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> COMMIT </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> No </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indicates whether a commit is performed after importing each row. By default, <i>importer makes</i> a commit after loading each table.</span> </td></tr>
<tr><td><span style="font-size: small;"> </span><span style="font-size: small;"> PARFILE </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> indefinite </span></td><td><span style="font-size: small;"> </span><span style="font-size: small;"> parameter file. </span></td></tr>
</tbody></table>
</center><br />
<div style="font-family: inherit; text-align: justify;">
<span style="font-size: small;"> </span><span style="font-size: small;"> To import an incremental <i>export</i> can be performed the following sequence of steps: </span></div>
<ol style="font-family: inherit; text-align: justify;">
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Using the latest copy of the <i>import</i> to restore the system definitions: </span><pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"><span style="color: green;">$ Imp userid = sys / passwd inctype = system file = full = Y export_filename</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Put the <i>rollback</i> segments <i>online.</i> </span></li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Import entire export file newest </span><pre><span style="color: green; font-size: small;"></span><span style="font-size: small;"></span></pre>
<pre><span style="font-size: small;"><span style="color: green;">$ Imp userid = sys / passwd inctype = restore full = Y file = filename</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</li>
<li><span style="font-size: small;"> </span><span style="font-size: small;"> Import export files in accumulation mode from the most recent full export, in chronological order: </span><pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> <span style="color: green;">$ Imp userid = sys / passwd inctype = restore full = Y file = filename</span> </span><span style="color: green; font-size: small;">
</span><span style="font-size: small;"> </span></pre>
</li>
<li><span style="font-size: small;"> Importar los ficheros de exportación en modo
incremental desde la exportación completa o acumulativa más reciente, en
orden cronológico: </span><pre><span style="font-size: small;"> </span><span style="color: green; font-size: small;">
$ imp userid=sys/passwd inctype=restore full=Y file=filename
</span><span style="font-size: small;"> </span></pre>
</li>
</ol>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-87277915687446881862011-06-05T22:04:00.000+05:302011-06-05T22:04:35.636+05:30Command scripts for Oracle and Sql Server<b><span><span style="font-family: Verdana; font-size: x-small;">To define a variable that is visible in the script you can use the command:</span></span></b><br />
<span><span style="font-family: Verdana; font-size: x-small;"> </span></span>
<br />
<div class="post-share-buttons" style="float: right; margin-left: 0px;">
</div>
<div class="post-body entry-content">
<br />
<div dir="ltr" style="text-align: left;">
<div class="separator" style="clear: both; text-align: center;">
</div>
</div>
</div>
<br />
<div style="text-align: justify;">
<a href="http://1.bp.blogspot.com/-fW4oxSkFDWs/TZszQP0fvaI/AAAAAAAAAQo/5bYst-1gmKY/s1600/MySQL%2BINSTALLATION%2Band%2BUN-INSTALLATION%2BCommands%2B%2Bmeansofmine.png" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img border="0" height="166" src="http://1.bp.blogspot.com/-fW4oxSkFDWs/TZszQP0fvaI/AAAAAAAAAQo/5bYst-1gmKY/s320/MySQL%2BINSTALLATION%2Band%2BUN-INSTALLATION%2BCommands%2B%2Bmeansofmine.png" width="320" /></a><span> <span style="font-family: Verdana; font-size: x-small;">DECLARE (in sqlserver): type is specified, it is NULL, then be initialized with SET or the result of a query</span></span> <span style="font-family: Verdana; font-size: x-small;"></span></div>
<div style="text-align: justify;">
<span style="font-family: Verdana; font-size: x-small;"><br /></span> <span> <span style="font-family: Verdana; font-size: x-small;">DEFINE
(in oracle): the variable is initialized with a text (not defined char
or varchar, only replace this text which use the variable).</span></span></div>
<div style="text-align: justify;">
<span><span style="font-family: Verdana; font-size: x-small;"> </span></span> </div>
<div style="text-align: justify;">
<span> <span style="font-family: Verdana; font-size: x-small;">In Oracle you can run the script from SQL * Plus as</span></span> <span style="font-family: Verdana; font-size: x-small;"><br /></span> <span> <i><span style="font-family: Verdana; font-size: x-small;">sta c: \ misscripts \ testeoBMS.sql</span></i></span></div>
<div style="text-align: justify;">
<span><i><span style="font-family: Verdana; font-size: x-small;"> </span></i></span> </div>
<div style="text-align: justify;">
<span> <span style="font-family: Verdana; font-size: x-small;">In SqlServer opens the script with query analyzer and run.</span></span> <span style="font-family: Verdana; font-size: x-small;"><br /></span> <span> <span style="font-family: Verdana; font-size: x-small;"> </span></span></div>
<div style="text-align: justify;">
<span><span style="font-family: Verdana; font-size: x-small;">Hope you practical.</span></span></div>
<div style="text-align: justify;">
<span><span style="font-family: Verdana; font-size: x-small;"> </span></span> </div>
<div style="text-align: justify;">
<span> <span style="font-family: Verdana; font-size: x-small;">/ * Script sqlserver to see results of a run of KBToolsWS * /</span></span> </div>
<div style="text-align: justify;">
<span> <i><span style="font-family: Verdana; font-size: x-small;">Int DECLARE @ vOpeNro</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"></span></i></div>
<div style="text-align: justify;">
<i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">/ * Number of last operation * /</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">set @ vOpeNro = (select max (OpenROSA) from Ope)</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"></span></i></div>
<div style="text-align: justify;">
<i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">/ * Can change this variable hand for another transaction number * /</span></i></span></div>
<div style="text-align: justify;">
<span><i><span style="font-family: Verdana; font-size: x-small;"> </span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">/ * Set @ vOpeNro = 32 * /</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"></span></i></div>
<div style="text-align: justify;">
<i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">/ * Operation * /</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">select * from operating WHERE = @ vOpeNro OpenROSA</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"></span></i></div>
<div style="text-align: justify;">
<i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">/ * KBSistemas last operation * /</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">select * from WHERE opekbs OpenROSA = @ vOpeNro</span></i></span></div>
<div style="text-align: justify;">
<span><i><span style="font-family: Verdana; font-size: x-small;"> </span></i></span> </div>
<div style="text-align: justify;">
<span> <span style="font-family: Verdana; font-size: x-small;">/ * <span class="825302616-07062002">For</span> testing Oracle Script ------------------ ------- <i>------------------- ---*/</i></span></span> </div>
<div style="text-align: justify;">
<span> <i><span style="font-family: Verdana; font-size: x-small;">clear screen</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">September feedback on</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">defined vruta = 99</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">defined vName = 'test Route 99'</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">Dress define = 'I'</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">defined vFecha = sysdate</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">vusuario = user defined</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">bmsrutas insert into values ('& vRUTA', '& vName', '& dressed', & vFECHA, '& vUSUARIO');</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">select LINESYS, LineNumber, LINENAME, CREATOR, CreateDate, Updator, UpdateData, CHAINAGEFROM</span></i></span> <i><span style="font-family: Verdana; font-size: x-small;"><br /></span></i> <span> <i><span style="font-family: Verdana; font-size: x-small;">WHERE bms.line from linenumber like '& vruta%';</span></i></span> </div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-4465796667391933042011-05-26T22:08:00.000+05:302011-05-26T22:08:27.481+05:30PL/SQL statement in Siebel eScript<div dir="ltr" style="text-align: left;" trbidi="on">
<div style="font-family: inherit;">
<span style="font-size: small;">Here is another interesting requirement wherein we are automating the
complete process. We need to call the Batch file during the course of a
workflow. The client wants to run some extracts on press of a button in
GUI. For this we can build a WF which incorporates a custom Business
Service to process the batch file we have written for extracting
records.</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;"><span id="more-1277"></span></span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">There can be two ways to fulfill this requirement:</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><ol style="font-family: inherit;">
<li><span style="font-size: small;"><strong>Clib.system() Method</strong></span></li>
<li><span style="font-size: small;"><strong>SElib.dynamicLink() Method</strong></span></li>
</ol>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">I have incorporated <strong>Clib.system()</strong> in my script. It’s
a one line statement with which I called the batch file and ran it
successfully. The format goes something like this <em>Clib.system(“D:\\CSExtract\\OLD\\extract_Test.bat”);</em> <strong><span style="color: grey;">(text in double quotes represents the exact path of the batch file)</span></strong></span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">Another important feature of this method is to execute any statement
from the command line; we can carry out any operation we want.</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">Clib.system(“copy c:\\test.txt c:\\shared\\test.txt”);</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">With the following example we can call the SQL procedure also</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">Clib.system(“sqlplus UserName/password@dbname @//SBA_81/siebsrvr/bin/TEST_PROCEDURE.SQL”);</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<br /></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;"><strong>SElib.dynamicLink()</strong> Method : I didn’t get a chance to work on this but I am presenting the format for the same.</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">SElib.dynamicLink(<em>Library, Procedure, Convention</em>[<em>, [desc,] arg1, arg2, arg3,</em> …, <em>arg</em>n])</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><table border="0" cellpadding="0" cellspacing="0" style="font-family: inherit;">
<tbody>
<tr>
<td valign="bottom" width="155"><span style="font-size: small;">Parameter</span></td>
<td valign="bottom" width="413"><span style="font-size: small;">Description</span></td>
</tr>
<tr>
<td valign="bottom" width="155"><span style="font-size: small;"><em>Library</em></span></td>
<td valign="bottom" width="413"><span style="font-size: small;">Under Windows, the name of the DLL
containing the procedure; under UNIX, the name of a shared object; can
be specified by fully qualified path name</span></td>
</tr>
<tr>
<td valign="bottom" width="155"><span style="font-size: small;">Procedure</span></td>
<td valign="bottom" width="413"><span style="font-size: small;">The name or ordinal number of the procedure in the Library dynamic link library</span></td>
</tr>
<tr>
<td valign="bottom" width="155"><span style="font-size: small;">Convention</span></td>
<td valign="bottom" width="413"><span style="font-size: small;">The calling convention</span></td>
</tr>
<tr>
<td valign="bottom" width="155"><span style="font-size: small;">desc</span></td>
<td valign="bottom" width="413"><span style="font-size: small;">Used to pass a Unicode string; for example, WCHAR</span></td>
</tr>
<tr>
<td valign="bottom" width="155"><span style="font-size: small;">arg1, arg2, arg3, …, argn</span></td>
<td valign="bottom" width="413"><span style="font-size: small;">Parameters to the procedure</span></td>
</tr>
</tbody>
</table>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<br /></div>
<div style="font-family: inherit;">
<span style="font-size: small;">For more on this please go through:</span></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;"><a href="http://download.oracle.com/docs/cd/E05553_01/books/eScript/eScript_JSReference244.html#wp1014383">http://download.oracle.com/docs/cd/E05553_01/books/eScript/eScript_JSReference244.html#wp1014383</a></span></div>
<div style="font-family: inherit;">
<br /></div>
<span style="font-size: small;"><span style="font-family: inherit;">
</span></span><div style="font-family: inherit;">
<span style="font-size: small;">These statements can be incorporated in the eScript to build a <strong>custom BS</strong>. We can then automate any job from a click of a button or any other way possible.</span></div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-42311976158296367682011-04-30T10:07:00.000+05:302011-04-30T10:07:33.140+05:30SQL program to print the fees of student whose roll no is given as input using function<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">FUNCTIONS<span style="mso-tab-count: 1;"> </span></span></b><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="mso-tab-count: 3;"> </span></span></div>
<span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"> </span>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">AIM:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: 1.0in;">
To write<span style="mso-spacerun: yes;"> </span>a PL/SQL program to print the fees of student
whose roll no is given as input using function.</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<br /></div>
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">ALGORITHM: </span></b>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><u><span style="text-decoration: none;"><br /></span></u></b></div>
<div class="MsoNormal">
<span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>Step 1:start the program</div>
<div class="MsoNormal">
<span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>Step 2:Create a function named
greatest with 3 input aruguments a,b,c</div>
<div class="MsoNormal">
<span style="mso-tab-count: 3;"> </span>and
output argument <span style="mso-spacerun: yes;"> </span>as g</div>
<div class="MsoNormal">
<span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>Step 3:If a is greater than b and c
then<span style="mso-spacerun: yes;"> </span>assign to g else check if b is </div>
<div class="MsoNormal">
<span style="mso-tab-count: 3;"> </span>greater
than assign 0 to g</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 4 .Return the
value of g.</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 5. Stop the
program</div>
<a name='more'></a><br />
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><u><span style="text-decoration: none;"><br /></span></u></b></div>
<b style="mso-bidi-font-weight: normal;"><u><span style="font-family: "Times New Roman","serif"; font-size: 14.0pt; mso-ansi-language: EN-US; mso-bidi-font-size: 12.0pt; mso-bidi-language: AR-SA; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: EN-US;"></span></u></b><b style="mso-bidi-font-weight: normal;"><u><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="text-decoration: none;"></span></span></u><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">PROGRAM:</span></b>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: 1.0in;">
Sql >create or replace
function<span style="mso-spacerun: yes;"> </span>fun(rno in number) return
number is n number;</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
2<span style="mso-spacerun: yes;"> </span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;"> </span>select fees into n from student where
sturno=rno;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;"> </span>return(n);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>5<span style="mso-spacerun: yes;"> </span>end;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;"> </span>/</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Warning: Function
created with compilation errors.</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
SQL> declare</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>2<span style="mso-spacerun: yes;"> </span>a number(5);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;"> </span>b number (8);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;"> </span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>5<span style="mso-spacerun: yes;"> </span>a:=&a;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;"> </span>b:=&b;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>7<span style="mso-spacerun: yes;"> </span>dbms_output.put_line(b);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>8<span style="mso-spacerun: yes;"> </span>end;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>9<span style="mso-spacerun: yes;"> </span>/</div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><u><span style="text-decoration: none;"><br /></span></u></b></div>
<b style="mso-bidi-font-weight: normal;"><u><span style="font-family: "Times New Roman","serif"; font-size: 14.0pt; mso-ansi-language: EN-US; mso-bidi-font-size: 12.0pt; mso-bidi-language: AR-SA; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: EN-US;"></span></u></b><b style="mso-bidi-font-weight: normal;"><u><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="text-decoration: none;"></span></span></u></b><b style="mso-bidi-font-weight: normal;"><u><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="text-decoration: none;"></span></span></u><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">OUTPUT:</span></b><div class="MsoNormal" style="text-indent: .5in;">
</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Enter value for a:
20</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
old<span style="mso-spacerun: yes;"> </span>5: a:=&a;</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
new<span style="mso-spacerun: yes;"> </span>5: a:=20;</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Enter value for b:
25</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
old<span style="mso-spacerun: yes;"> </span>6: b:=&b;</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
new<span style="mso-spacerun: yes;"> </span>6: b:=25;</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
PL/SQL procedure
successfully completed.</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-10175073177769695822011-04-30T10:05:00.000+05:302011-04-30T10:05:05.893+05:30SQL program to create functions for finding greatest of three numbers<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">FUNCTIONS</span></b></div>
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">AIM:</span></b><div class="MsoNormal" style="margin-left: 1in;">
<b><span style="font-size: 14pt;"> </span></b><span style="mso-tab-count: 1;"> </span>To write a mysql program to create
functions for finding greatest of three numbers.</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"> </span></b><b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">ALGORITHM:</span></b></div>
<div class="MsoNormal">
<b><span style="font-size: 14pt;"> </span></b>
</div>
<b style="mso-bidi-font-weight: normal;"><span style="mso-tab-count: 1;"> </span></b>Step 1:<span style="mso-spacerun: yes;"> </span>Start the program
<div class="MsoNormal" style="margin-left: .5in;">
Step 2. Create a function named
greatest with 3 input aruguments a,b,c and output </div>
<div class="MsoNormal" style="margin-left: .5in;">
<span style="mso-tab-count: 1;"> </span>argument
<span style="mso-spacerun: yes;"> </span>as g</div>
<div class="MsoNormal">
<span style="mso-tab-count: 1;"> </span>Step 3 .If
a is greater than b and c then<span style="mso-spacerun: yes;"> </span>assign to
g else check if b is greater than </div>
<div class="MsoNormal">
<span style="mso-tab-count: 2;"> </span>assign
0 to g</div>
<div class="MsoNormal" style="text-indent: .5in;">
Step 4 .Return the value of g.</div>
<div class="MsoNormal" style="text-indent: .5in;">
Step 5. Stop the program</div>
<a name='more'></a><br />
<br /><div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">PROGRAM:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
SQL> create or replace function
greater (a in number,b in number,c in number)return number is g numbers</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>2<span style="mso-spacerun: yes;">
</span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;">
</span>if (a>b) then</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;">
</span>g:=a;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>5<span style="mso-spacerun: yes;">
</span>else</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;">
</span>g:=b;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>7<span style="mso-spacerun: yes;">
</span>if(c>g)then</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>8<span style="mso-spacerun: yes;">
</span>g:=c;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>9<span style="mso-spacerun: yes;">
</span>end if;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>10<span style="mso-spacerun: yes;">
</span>end if;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>11<span style="mso-spacerun: yes;">
</span>return(g);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>12<span style="mso-spacerun: yes;">
</span>end;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>13<span style="mso-spacerun: yes;">
</span>/</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>Function created</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
SQL> declare a number(3);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>2<span style="mso-spacerun: yes;">
</span>b number(3);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;">
</span>c number(3);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;">
</span>d number(3);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span>5<span style="mso-spacerun: yes;"> </span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;">
</span>a:=&a;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>7<span style="mso-spacerun: yes;">
</span>b:=&b;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>8<span style="mso-spacerun: yes;">
</span>c:=&c;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>9<span style="mso-spacerun: yes;">
</span>d:=greater(a,b,c);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>10<span style="mso-spacerun: yes;">
</span>dbms_output.put_line(d);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>11<span style="mso-spacerun: yes;">
</span>end;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>12<span style="mso-spacerun: yes;">
</span>/</div>
<br /><div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">OUTPUT:</span></b></div>
<div class="MsoNormal" style="text-indent: .5in;">
Enter value for a: 45</div>
<div class="MsoNormal" style="text-indent: .5in;">
old<span style="mso-spacerun: yes;"> </span>6: a:=&a;</div>
<div class="MsoNormal" style="text-indent: .5in;">
new<span style="mso-spacerun: yes;"> </span>6: a:=45;</div>
<div class="MsoNormal" style="text-indent: .5in;">
Enter value for b: 35</div>
<div class="MsoNormal" style="text-indent: .5in;">
old<span style="mso-spacerun: yes;"> </span>7: b:=&b;</div>
<div class="MsoNormal" style="text-indent: .5in;">
new<span style="mso-spacerun: yes;"> </span>7: b:=35;</div>
<div class="MsoNormal" style="text-indent: .5in;">
Enter value for c: 25</div>
<div class="MsoNormal" style="text-indent: .5in;">
old<span style="mso-spacerun: yes;"> </span>8: c:=&c;</div>
<div class="MsoNormal" style="text-indent: .5in;">
new<span style="mso-spacerun: yes;"> </span>8: c:=25;</div>
<div class="MsoNormal" style="text-indent: .5in;">
45</div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
SQL<span style="mso-spacerun: yes;">
</span>procedure successfully completed.</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-23787037289803774502011-04-30T10:02:00.000+05:302011-04-30T10:02:02.956+05:30SQL program to create triggers for deletion and updating operation<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Times New Roman","serif";}
</style>
<![endif]-->
<br />
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 16.0pt;">HIGH LEVEL LANGUAGE EXTENSION</span></b></div>
<div>
</div>
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span></b><b style="mso-bidi-font-weight: normal;"><span style="font-size: 16.0pt;"><span style="mso-tab-count: 4;"></span>WITH
TRIGGERRS</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="text-align: justify;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 15.0pt; mso-bidi-font-size: 12.0pt;">AIM:</span></b></div>
<div class="MsoNormal" style="margin-left: .5in; text-align: justify;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-align: justify;">
To write a
mysql program to create triggers for deletion and updating operation.</div>
<div class="MsoNormal" style="text-align: justify; text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="text-align: justify;">
<br /></div>
<div class="MsoNormal" style="text-align: justify;">
<br /></div>
<div class="MsoNormal" style="text-align: justify;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 15.0pt; mso-bidi-font-size: 12.0pt;">Algorithm:</span></b></div>
<div class="MsoNormal" style="margin-left: 72.4pt; mso-list: l0 level1 lfo1; tab-stops: list 72.4pt; text-align: justify; text-indent: -.25in;">
<span style="mso-list: Ignore;">1.<span style="font: 7.0pt "Times New Roman";">
</span></span>start the program.</div>
<div class="MsoNormal" style="margin-left: 72.4pt; mso-list: l0 level1 lfo1; tab-stops: list 72.4pt; text-align: justify; text-indent: -.25in;">
<span style="mso-list: Ignore;">2.<span style="font: 7.0pt "Times New Roman";">
</span></span>2.create a trigger named t1 for deletion and updation
operation.</div>
<div class="MsoNormal" style="margin-left: 72.4pt; mso-list: l0 level1 lfo1; tab-stops: list 72.4pt; text-align: justify; text-indent: -.25in;">
<span style="mso-list: Ignore;">3.<span style="font: 7.0pt "Times New Roman";">
</span></span>if deletion or updation operation is performed. Then if
raises an error’no updation’ or ’no deletion’.</div>
<div class="MsoNormal" style="margin-left: 72.4pt; mso-list: l0 level1 lfo1; tab-stops: list 72.4pt; text-align: justify; text-indent: -.25in;">
<span style="mso-list: Ignore;">4.<span style="font: 7.0pt "Times New Roman";">
</span></span>stop the program.</div>
<a name='more'></a><br />
<div align="right" class="MsoNormal" style="text-align: right;">
<span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="mso-tab-count: 3;"> </span><b style="mso-bidi-font-weight: normal;"><u><span style="mso-spacerun: yes;"><br /></span></u></b></span></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 16.0pt; mso-bidi-font-size: 12.0pt;">Program:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
Sql>create or replace trigger t1
before insert on ngj for each row</div>
<div class="MsoNormal" style="margin-left: .5in;">
2 begin</div>
<div class="MsoNormal" style="margin-left: .5in;">
3 if(:new.sturno>8)then
raise_application_error(-20010,’cannor possible’);</div>
<div class="MsoNormal" style="margin-left: .5in;">
4 end if;</div>
<div class="MsoNormal" style="margin-left: .5in;">
5 end;</div>
<div class="MsoNormal" style="margin-left: .5in;">
6 /</div>
<div class="MsoNormal" style="margin-left: .5in;">
Trigger created.</div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: 0.5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: 0.5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
Sql>insert into ngj values(7,’kumar’,’mech’,erd’,20000);</div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
1row created.</div>
<div class="MsoNormal" style="margin-left: .5in;">
Sql>create or replace trigger t2
before delete or update on ngj for each row</div>
<div class="MsoNormal" style="margin-left: .5in;">
2 begin</div>
<div class="MsoNormal" style="margin-left: .5in;">
3 if updating then
raise_application_error (-20013,’no updation’);</div>
<div class="MsoNormal" style="margin-left: .5in;">
4 end if;</div>
<div class="MsoNormal" style="margin-left: .5in;">
5 if deleting then
raise_application_error (-20014,’no deletion’);</div>
<div class="MsoNormal" style="margin-left: .5in;">
6 end if;</div>
<div class="MsoNormal" style="margin-left: .5in;">
7 end;</div>
<div class="MsoNormal" style="margin-left: .5in;">
8 /</div>
<div class="MsoNormal" style="margin-left: .5in;">
Trigger created.</div>
<br /><div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 16.0pt; mso-bidi-font-size: 12.0pt;">Output:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
Sql>insert into ngj values (11,’siva’,’it’,
erd’, 20000);</div>
<div class="MsoNormal" style="margin-left: .5in;">
Insert into ngj values (11,’siva’,’it’,’erd’,
20000)</div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
ERROR AT LINE 1:</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-20010: cannot possible</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-06512: at”SCOTT.T1”,line 2</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-04088: error during execution
of trigger’SCOTT.T1’</div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
SQL>delete from ngj where
sturno=7; </div>
<div class="MsoNormal" style="margin-left: .5in;">
delete from ngj where sturno=7; </div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
ERROR AT LINE 1:</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-20010: cannot possible</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-06512: at”SCOTT.T2”, line 4</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-04088: error during execution
of trigger’SCOTT.T2’</div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
Sql>update ngj set fes=34000
where course=’cse’</div>
<div class="MsoNormal" style="margin-left: .5in;">
2/</div>
<div class="MsoNormal" style="margin-left: .5in;">
Update ngj set fees=34000 where
course=’cse’</div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in;">
ERROR AT LINE 1:</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-20010: cannot possible</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-06512: at”SCOTT.T2”, line 4</div>
<div class="MsoNormal" style="margin-left: .5in;">
ORA-04088: error during execution
of trigger’SCOTT.T2’</div>
<div class="MsoNormal" style="margin-left: .5in;">
<br /></div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-5441228094109347502011-04-30T10:00:00.000+05:302011-04-30T10:00:00.691+05:30SQL program for high level language extension with implict cursor<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if !mso]><img src="http://img2.blogblog.com/img/video_object.png" style="background-color: #b2b2b2; " class="BLOGGER-object-element tr_noresize tr_placeholder" id="ieooui" data-original-id="ieooui" />
<style>
st1\:*{behavior:url(#ieooui) }
</style>
<![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">HIGHLEVEL LANGUAGE EXTENSION</span></b></div>
<div>
</div>
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="mso-tab-count: 3;"></span>WITH IMPLICIT CURSOR</span></b></div>
<div align="center" class="MsoNormal" style="text-align: center;">
<br /></div>
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">AIM:</span></b><div class="MsoNormal" style="text-indent: .5in;">
</div>
<span style="mso-tab-count: 1;"></span>To write a PL/SQL program for high
level language extension with implict cursor.
<div class="MsoNormal" style="margin-left: 1.0in;">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="mso-spacerun: yes;"></span><span style="mso-spacerun: yes;"></span><span style="mso-tab-count: 2;"></span></b><b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">ALGORITHM:</span></b>
</div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="mso-tab-count: 2;"> </span></b>Step 1:<span style="mso-spacerun: yes;"> </span>Start the program</div>
<div class="MsoNormal">
<span style="mso-tab-count: 2;"> </span>Step
2:<span style="mso-tab-count: 1;"> </span> create the cursor named cur1 &
cur2</div>
<div class="MsoNormal" style="margin-left: 1.0in;">
Step 3: store cur1 divided by row wise
in √1 & cur2 divide by<span style="mso-spacerun: yes;"> </span>row wise </div>
<div class="MsoNormal" style="margin-left: 1.0in;">
<span style="mso-spacerun: yes;"> </span>in √2</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 4: fetch the
values for I from 1to c</div>
<div class="MsoNormal" style="margin-left: 1.0in;">
Step 5: <span style="mso-spacerun: yes;"> </span>for each display stu no,stu name, course,
address fees from cur1 & </div>
<div class="MsoNormal" style="margin-left: 1.0in;">
<span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span>batch from cur2</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 6: Stop the
program</div>
<a name='more'></a><br />
<div class="MsoNormal">
<span style="mso-tab-count: 2;"> </span><u><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span></u></div>
<div class="MsoNormal">
<u><span style="font-size: 14pt;"><span style="text-decoration: none;"></span></span></u><b>PROGRAM:</b></div>
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span></b><div class="MsoNormal">
</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>SQL>
set serveroutput on</div>
<div class="MsoNormal" style="text-indent: .5in;">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>SQL>
declare</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>2<span style="mso-spacerun: yes;"> </span>cursor cur1 is select * from fanta;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;"> </span>cursor cur2 is select * from munch;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;"> </span>r1 cur1 %rowtype;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>5<span style="mso-spacerun: yes;"> </span>r2 cur2 %rowtype;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;"> </span>c number;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>7<span style="mso-spacerun: yes;"> </span>i number;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>8<span style="mso-spacerun: yes;"> </span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>9<span style="mso-spacerun: yes;"> </span>select count (*) into c from fanta;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>10<span style="mso-spacerun: yes;"> </span>for i in 1...c</div>
<div class="MsoNormal" style="text-indent: .5in;">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>11<span style="mso-spacerun: yes;"> </span>loop</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>12<span style="mso-spacerun: yes;"> </span>select * into r1 from fanta where rupees=i;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>13<span style="mso-spacerun: yes;"> </span>select * into r2 from munch where rupees=i;</div>
<div class="MsoNormal" style="margin-left: 1.0in;">
14<span style="mso-spacerun: yes;">
</span>dbms_output.put_line <span style="mso-spacerun: yes;"> </span>('r1.name'||'r1.brand'||'r1.rupees'||'r2.name'||'r2.brand'||'r2.rupees');</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>15<span style="mso-spacerun: yes;"> </span>end loop;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>16<span style="mso-spacerun: yes;"> </span>end;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>17<span style="mso-spacerun: yes;"> </span>/</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span></div>
<span style="font-family: "Times New Roman","serif"; font-size: 14.0pt; mso-ansi-language: EN-US; mso-bidi-font-size: 12.0pt; mso-bidi-language: AR-SA; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: EN-US;"></span><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span><b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">OUTPUT:</span></b><div class="MsoNormal">
</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
1 <span style="mso-tab-count: 1;"> </span>NEHA<span style="mso-tab-count: 2;"> </span>ECE<span style="mso-tab-count: 1;"> </span>ERODE<span style="mso-tab-count: 1;"> </span>20000<span style="mso-tab-count: 1;"> </span>1</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
2<span style="mso-tab-count: 1;"> </span>NISHA<span style="mso-tab-count: 1;"> </span>CSE<span style="mso-tab-count: 1;"> </span>KARUR<span style="mso-tab-count: 1;"> </span>20000<span style="mso-spacerun: yes;"> </span>2</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
3<span style="mso-tab-count: 1;"> </span>JANA<span style="mso-tab-count: 2;"> </span>MECH<span style="mso-tab-count: 1;"> </span>NKL<span style="mso-tab-count: 2;"> </span>25000<span style="mso-spacerun: yes;"> </span>2</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
4<span style="mso-tab-count: 1;"> </span>HARI<span style="mso-tab-count: 2;"> </span>IT<span style="mso-tab-count: 1;"> </span>SALEM<span style="mso-tab-count: 1;"> </span>25000<span style="mso-spacerun: yes;">
</span>3</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
5<span style="mso-spacerun: yes;"> </span>AACHU<span style="mso-tab-count: 1;"> </span>CSE<span style="mso-tab-count: 1;"> </span>CHENNAI<span style="mso-tab-count: 1;"> </span>25000<span style="mso-spacerun: yes;"> </span>4</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-24735946122306500582011-04-30T09:57:00.000+05:302011-04-30T09:57:25.039+05:30SQL program for high level language extension with explict cursor<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>HIGHLEVEL LANGUAGE EXTENSION</span></b></div>
<div>
</div>
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="mso-tab-count: 3;"></span>WITH EXPLICIT CURSOR</span></b></div>
<div align="center" class="MsoNormal" style="text-align: center;">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">AIM:</span></b></div>
<div class="MsoNormal" style="margin-left: .5in;">
<span style="mso-spacerun: yes;">
</span>To write a PL/SQL program for high level language extension with explict
cursor</div>
<br />
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">ALGORITHM:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="mso-tab-count: 2;"> </span></b>Step 1:<span style="mso-spacerun: yes;"> </span>Start the program</div>
<div class="MsoNormal">
<span style="mso-tab-count: 2;"> </span>Step
2:<span style="mso-tab-count: 1;"> </span>create a cursor named c1 & store c
divided row wise in r1</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 3 : fetch c1
into √1 until √1 value found<span style="mso-spacerun: yes;"> </span></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 4 : print the
value of student no & student name</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 5: display
the value of a as result</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 6 : Stop the
program</div>
<a name='more'></a><br />
<div class="MsoNormal">
<span style="mso-tab-count: 1;"> </span></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">PROGRAM:</span></b></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Sql > set
server output on</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>Sql> 1<span style="mso-spacerun: yes;"> </span>declare</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>2<span style="mso-spacerun: yes;"> </span>cursor cl is select * from jumbo;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>3<span style="mso-spacerun: yes;"> </span>r1 cl % rowtype;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>4<span style="mso-spacerun: yes;"> </span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>5<span style="mso-spacerun: yes;"> </span>open cl;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>6<span style="mso-spacerun: yes;"> </span>loop</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>7<span style="mso-spacerun: yes;"> </span>fetch cl into r1;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>8<span style="mso-spacerun: yes;"> </span>dbms_output.put_line(r1.dept||''||r1.name)</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>9<span style="mso-spacerun: yes;"> </span>exit when cl% notfound ;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>10<span style="mso-spacerun: yes;"> </span>end loop;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>11<span style="mso-spacerun: yes;"> </span>close cl;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 2;"> </span>12* end;</div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">OUTPUT:</span></b>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Eee<span style="mso-spacerun: yes;"> </span>sandy</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Cse<span style="mso-spacerun: yes;"> </span>sathees</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Cse<span style="mso-spacerun: yes;"> </span>sathees</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
PL/SQL procedure
successfully completed.</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-86118496692721218252011-04-30T08:48:00.000+05:302011-04-30T08:48:06.731+05:30SQL program for high level language extension with simple cursor<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">HIGH-LEVEL LANGUAGE
EXTENSION</span></b><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span></div>
<div>
</div>
<div class="MsoNormal" style="text-align: center;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="mso-spacerun: yes;"></span></span></b><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><b style="mso-bidi-font-weight: normal;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>WITH SIMPLE CURSOR</b></span></div>
<div style="text-align: center;">
</div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"><span style="mso-spacerun: yes;"></span></span></b><b>AIM:</b><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span></div>
<div class="MsoNormal" style="margin-left: 1.0in; text-indent: 3.0pt;">
To write a
PL/SQL program for high level language extension with simple cursor</div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="text-align: left;">
<b style="mso-bidi-font-weight: normal;"><span style="mso-spacerun: yes;"></span><span style="mso-spacerun: yes;"></span></b><b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">ALGORITHM:</span></b></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="mso-tab-count: 2;"> </span></b>Step 1:<span style="mso-spacerun: yes;"> </span>Start the program</div>
<div class="MsoNormal">
<span style="mso-tab-count: 2;"> </span>Step
2:<span style="mso-tab-count: 1;"> </span> declare the cursor named cur</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 3 :<span style="mso-spacerun: yes;"> </span>if not cur is open then print ‘yet<span style="mso-spacerun: yes;"> </span>to be opened’</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 4 : if cur is
opened then print ‘cursor is opened’</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 5: display the
value of a as result</div>
<div class="MsoNormal" style="text-indent: 0.5in;">
Step 6 : Stop the
program<span style="mso-tab-count: 1;"></span><b><span style="font-size: 14pt;"> </span></b></div>
<a name='more'></a><br />
<br />
<b><span style="font-size: 14pt;">PROGRAM:</span></b><br />
<div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>SQL> set serveroutput on</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
SQL> declare</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>2<span style="mso-spacerun: yes;"> </span>cursor cur is select * from jumbo;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;"> </span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;"> </span>if not cur% isopen then</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>5<span style="mso-spacerun: yes;"> </span>dbms_output.put_line('yet<span style="mso-spacerun: yes;"> </span>to be opened');</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;"> </span>end if;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>7<span style="mso-spacerun: yes;"> </span>open cur;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>8<span style="mso-spacerun: yes;"> </span>if cur% isopen then</div>
<div class="MsoNormal" style="text-indent: .5in;">
<span style="mso-spacerun: yes;">
</span><span style="mso-tab-count: 1;"> </span>9<span style="mso-spacerun: yes;"> </span>dbms_output.put_line('cursor opened');</div>
<div class="MsoNormal" style="text-indent: .5in;">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>10<span style="mso-spacerun: yes;"> </span>end if;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>11<span style="mso-spacerun: yes;"> </span>close cur;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>12<span style="mso-spacerun: yes;"> </span>end;</div>
<div class="MsoNormal" style="text-indent: .5in;">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>13<span style="mso-spacerun: yes;"> </span>/</div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">OUTPUT:</span></b></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
yet<span style="mso-spacerun: yes;"> </span>to be opened</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
cursor opened</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
PL/SQL procedure
successfully completed.</div>
</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-9384072009271347402011-04-30T08:44:00.000+05:302011-04-30T08:44:34.077+05:30SQL program for finding the odd or even<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div align="center" class="MsoNormal" style="text-align: center;">
<u><b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">PL/SQL
PROGRAM<span style="mso-spacerun: yes;"> </span>ODD OR EVEN</span></b></u></div>
<div class="MsoNormal">
<u><span style="text-decoration: none;"></span></u><span style="mso-spacerun: yes;"></span><b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">AIM:</span></b></div>
<span style="mso-tab-count: 1;"></span>To write a program to create
functions for finding the odd or even<span style="mso-spacerun: yes;"> </span>numbers
<div class="MsoNormal" style="margin-left: 1.0in;">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="mso-spacerun: yes;"></span></b><b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">ALGORITHM:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="mso-tab-count: 2;"> </span></b>Step 1:<span style="mso-spacerun: yes;"> </span>Start the program</div>
<div class="MsoNormal">
<span style="mso-tab-count: 2;"> </span>Step
2:<span style="mso-tab-count: 1;"> </span> declare the variables </div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;">
</span>Step 3 : get the values of a</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 4:<span style="mso-spacerun: yes;"> </span>check whether a mod 2 is equal to 0</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 5: <span style="mso-spacerun: yes;"> </span>then print number is even else print the
number is odd</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 6 : Stop the
program</div>
<a name='more'></a><br />
<br />
<b><span style="font-size: 14pt;">PROGRAM:</span></b>
<br />
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
SQL> set
serveroutput on</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
SQL> declare A
number(5);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>2<span style="mso-spacerun: yes;"> </span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;">
</span>a:=&a;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;"> </span>if(A mod 2=0) then</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;"> </span>dbms_output.put_line('number of odd');</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>5<span style="mso-spacerun: yes;"> </span>else</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;"> </span>dbms_output.put_line('number of odd');</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>7<span style="mso-spacerun: yes;"> </span>end if;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>8<span style="mso-spacerun: yes;"> </span>end;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span><span style="mso-tab-count: 1;"> </span>9<span style="mso-spacerun: yes;"> </span>/</div>
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-ansi-language: EN-US; mso-bidi-language: AR-SA; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: EN-US;"><br clear="all" style="mso-special-character: line-break; page-break-before: always;" />
</span>
<div class="MsoNormal">
<br /></div>
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">OUTPUT:</span></b>
<div class="MsoNormal" style="text-indent: .5in;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span></b><b style="mso-bidi-font-weight: normal;"></b></div>
<div class="MsoNormal" style="text-indent: 0.5in;">
<b><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"></span></b>Enter the number
:= 15
</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
number of odd</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
PL/SQL procedure
successfully completed.</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-59135722262148993912011-04-30T08:41:00.000+05:302011-04-30T08:41:18.526+05:30SQL program for finding the Fibonacci series<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Times New Roman","serif";}
</style>
<![endif]-->
<br />
<div align="center" class="MsoNormal" style="text-align: center;">
<u><b style="mso-bidi-font-weight: normal;"><span lang="PT-BR" style="font-size: 14.0pt; mso-ansi-language: PT-BR; mso-bidi-font-size: 12.0pt;">PL/SQL PROGRAM<span style="mso-spacerun: yes;">
</span>FIBONACCI SERIES</span></b></u><u><span lang="PT-BR" style="mso-ansi-language: PT-BR;"></span></u></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"> AIM:</span></b></div>
<div class="MsoNormal">
<span style="mso-tab-count: 1;"> </span></div>
<div class="MsoNormal" style="text-indent: .5in;">
To write a program to create
functions for finding the Fibonacci series</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;"> ALGORITHM:</span></b></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="mso-tab-count: 2;"> </span></b></div>
<div class="MsoNormal" style="text-indent: .5in;">
Step 1:<span style="mso-spacerun: yes;"> </span>Start the program</div>
<div class="MsoNormal">
<span style="mso-tab-count: 1;"> </span>Step 2:<span style="mso-tab-count: 1;"> </span> declare the variables </div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span>Step 3 :<span style="mso-spacerun: yes;"> </span>initialize a=-1,b=-1 and i=1</div>
<div class="MsoNormal" style="margin-left: .5in;">
Step 4 : get the value of a</div>
<div class="MsoNormal" style="text-indent: .5in;">
Step 5: if n is less than or equal
to 0 ,then print 1 type correct </div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Value of n</div>
<div class="MsoNormal" style="text-indent: .5in;">
Step 6: while I is less than or
equal to n then</div>
<div class="MsoNormal" style="margin-left: 1.25in; mso-list: l0 level1 lfo1; tab-stops: list 1.25in; text-indent: -.25in;">
<span style="mso-list: Ignore;">a)<span style="font: 7.0pt "Times New Roman";"> </span></span>calculate
c as the sum of a & b</div>
<div class="MsoNormal" style="margin-left: 1.25in; mso-list: l0 level1 lfo1; tab-stops: list 1.25in; text-indent: -.25in;">
<span style="mso-list: Ignore;">b)<span style="font: 7.0pt "Times New Roman";"> </span></span>print
the value of c</div>
<div class="MsoNormal" style="margin-left: 1.25in; mso-list: l0 level1 lfo1; tab-stops: list 1.25in; text-indent: -.25in;">
<span style="mso-list: Ignore;">c)<span style="font: 7.0pt "Times New Roman";"> </span></span>store
the value b to a</div>
<div class="MsoNormal" style="margin-left: 1.25in; mso-list: l0 level1 lfo1; tab-stops: list 1.25in; text-indent: -.25in;">
<span style="mso-list: Ignore;">d)<span style="font: 7.0pt "Times New Roman";"> </span></span>store
the value of c to b</div>
<div class="MsoNormal" style="margin-left: 1.25in; mso-list: l0 level1 lfo1; tab-stops: list 1.25in; text-indent: -.25in;">
<span style="mso-list: Ignore;">e)<span style="font: 7.0pt "Times New Roman";"> </span></span>increment
the value of I by 1</div>
<div class="MsoNormal" style="text-indent: .5in;">
Step 7 : Stop the program</div>
<a name='more'></a><br />
<br /><div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;">PROGRAM:</b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
SQL> set serveroutput on</div>
<div class="MsoNormal" style="text-indent: .5in;">
SQL> declare A number(5):=0;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>2<span style="mso-spacerun: yes;">
</span>b number(5):=1;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>3<span style="mso-spacerun: yes;">
</span>c number(5);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>4<span style="mso-spacerun: yes;">
</span>i number(5):=2;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>5<span style="mso-spacerun: yes;">
</span>n number(5);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>6<span style="mso-spacerun: yes;">
</span>begin</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>7<span style="mso-spacerun: yes;">
</span>n:=&n;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>8<span style="mso-spacerun: yes;">
</span>dbms_output.put_line(A);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>9<span style="mso-spacerun: yes;">
</span>dbms_output.put_line(b);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>10<span style="mso-spacerun: yes;">
</span>while(i<n)</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>11<span style="mso-spacerun: yes;">
</span>loop</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>12<span style="mso-spacerun: yes;">
</span>c:=A+b;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>13<span style="mso-spacerun: yes;">
</span>dbms_output.put_line(c);</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>14<span style="mso-spacerun: yes;">
</span>A:=b;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>15<span style="mso-spacerun: yes;">
</span>b:=c;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>16<span style="mso-spacerun: yes;">
</span>i:=i+1;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>17<span style="mso-spacerun: yes;">
</span>end loop;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>18<span style="mso-spacerun: yes;">
</span>end;</div>
<div class="MsoNormal">
<span style="mso-spacerun: yes;"> </span><span style="mso-tab-count: 1;"> </span>19<span style="mso-spacerun: yes;">
</span>/</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">OUTPUT</span></b><span style="font-size: 14.0pt; mso-bidi-font-size: 12.0pt;">:</span></div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
Enter value for n: 5</div>
<div class="MsoNormal" style="text-indent: .5in;">
old<span style="mso-spacerun: yes;"> </span>7: n:=&n;</div>
<div class="MsoNormal" style="text-indent: .5in;">
new<span style="mso-spacerun: yes;"> </span>7: n:=5;</div>
<div class="MsoNormal" style="text-indent: .5in;">
0</div>
<div class="MsoNormal" style="text-indent: .5in;">
1</div>
<div class="MsoNormal" style="text-indent: .5in;">
1</div>
<div class="MsoNormal" style="text-indent: .5in;">
2</div>
<div class="MsoNormal" style="text-indent: .5in;">
3</div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="text-indent: .5in;">
PL/SQL procedure successfully
completed.</div>
</div>Unknownnoreply@blogger.com1tag:blogger.com,1999:blog-2138855673652777881.post-24155772016966855112011-04-30T08:37:00.003+05:302011-04-30T08:39:21.183+05:30SQL program for finding factorial for given numbers<div dir="ltr" style="text-align: left;" trbidi="on">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14pt;">ALGORITHM:</span></b><br />
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"> </b>Step 1: Start the program</div>
<div class="MsoNormal">
Step
2: declare the variables </div>
<div class="MsoNormal">
Step 3 : initialize a=0 and b=1</div>
<div class="MsoNormal" style="margin-left: 1.0in;">
Step 4 : get the value of a and b
by incrementing value of b up to c and store in a</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 5: display
the value of a as result</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 6 : Stop the
program<br />
<a name='more'></a> </div>
<br />
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14pt;">PROGRAM:</span></b></div>
<div class="MsoNormal" style="margin-left: .5in;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 20pt;">
</span></b></div>
<div class="MsoNormal">
SQL>set server output on</div>
<div class="MsoNormal">
SQL>declare</div>
<div class="MsoNormal">
a number (5):=1;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
b number (5):=1;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
c number (5):=;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
begin</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
c:=&c;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
for b in 1.. c loop </div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
a:a*b;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
end loop;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
dbms_output.put_line (a);</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
end;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
<br /></div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
<b style="mso-bidi-font-weight: normal;"><span style="font-size: 14pt;">OUTPUT: </span> </b></div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
<br /></div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
Enter the value for c:5</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
Old 6:c=&c;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
New 6:c:=5;</div>
<div class="MsoNormal" style="tab-stops: 87.75pt;">
120</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-16647966692891177372011-04-30T08:33:00.001+05:302011-04-30T08:33:39.790+05:30SQL program for finding the sum of n-numbers<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div align="center" class="MsoNormal" style="text-align: center; text-indent: .5in;">
<b style="mso-bidi-font-weight: normal;">PL/SQL PROGRAM SUM OF N NUMBERS</b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
</div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;">AIM:</b></div>
<div class="MsoNormal">
</div>
<div class="MsoNormal" style="text-indent: .5in;">
To
write a program to create functions for finding the sum of n-numbers</div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"> </b></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"> ALGORITHM:</b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"> </b>Step 1: Start the program</div>
<div class="MsoNormal">
Step
2: declare the variables </div>
<div class="MsoNormal">
Step 3 : initialize a=0 and b=1</div>
<div class="MsoNormal" style="margin-left: 1.0in;">
Step 4 : get the value of a and b
by incrementing value of b upto c and store in a</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 5: display
the value of a as result</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Step 6 : Stop the program</div>
<div class="MsoNormal">
<br />
<a name='more'></a><br /></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;">PROGRAM:</b></div>
<br />
SQL> set
serveroutput on
<br />
<div class="MsoNormal">
SQL> declare</div>
<div class="MsoNormal">
2 a number (5)=0;</div>
<div class="MsoNormal">
3 b number (5);</div>
<div class="MsoNormal">
4 c number (5);</div>
<div class="MsoNormal">
5 begin</div>
<div class="MsoNormal">
6 c:=&c;</div>
<div class="MsoNormal">
7 for b in 1...c loop</div>
<div class="MsoNormal">
8 a:=a+b;</div>
<div class="MsoNormal">
9 end loop;</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
10 dbms_output.put_line(a);</div>
<div class="MsoNormal">
11 end ;</div>
<div class="MsoNormal" style="text-indent: .5in;">
12 /</div>
<span style="font-family: "Times New Roman","serif"; font-size: 12pt;"><br clear="all" style="page-break-before: always;" />
</span>
<br />
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<span style="font-size: 14pt;"> <b style="mso-bidi-font-weight: normal;">OUTPUT</b>:</span><br />
<div>
<div class="MsoNormal" style="text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Enter value for c:
12</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
old 6: c:=&c;</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
new 6: c:=12;</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
78</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
<br /></div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
Pl/sql procedure successfully complet</div>
<div class="MsoNormal" style="margin-left: .5in; text-indent: .5in;">
<br /></div>
</div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-81214836778369963582011-04-30T08:17:00.000+05:302011-04-30T08:17:27.708+05:30DML & DCL commands in RDBMS<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if !mso]><img src="http://img2.blogblog.com/img/video_object.png" style="background-color: #b2b2b2; " class="BLOGGER-object-element tr_noresize tr_placeholder" id="ieooui" data-original-id="ieooui" />
<style>
st1\:*{behavior:url(#ieooui) }
</style>
<![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div class="MsoNormal">
<u><b><span style="font-family: "Times New Roman","serif"; font-size: 14.0pt; line-height: 115%;">DML &DCL COMMANDS:</span></b></u></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 14.0pt; line-height: 115%;">1.</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"> CREATE COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Create table
tablename ( fieldname column datatype(size));</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used to create a new table.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">2.INSERT COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Insert into
tablename values(‘& fieldname’…….);</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used to insert the values into table.</span></div>
<a name='more'></a><br />
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">3.UPDATE COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Update
tablename set fieldname=values;</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used to update the table values when new fields are added using
alter command.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">4.DELETE COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Delete from
tablename where fieldname=value;</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Deleting the row which contain the values mentioned.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">5.ROLL BACK COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span><span style="mso-spacerun: yes;"> </span>Rollback;<span style="mso-spacerun: yes;"> </span></span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used to undo the last performed operation.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">6.GRANT COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Grant
select,insert,update,delete on tablename to public.</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used to grant permission to perform mentioned operation.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">7.TO CHECK:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Selete operation is used after each query execution to check whether the
corresponding operations are performed.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">8.REVOKE COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>Revoke selete ,insert,
update ,delete on tablename from public.</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used to cancel the permission provided by grant operations.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<br /></div>
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-ansi-language: EN-US; mso-bidi-language: AR-SA; mso-fareast-font-family: Calibri; mso-fareast-language: EN-US;"><br clear="all" style="page-break-before: always;" />
</span>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><u><span style="font-family: "Times New Roman","serif"; font-size: 14.0pt; line-height: 115%; mso-bidi-font-size: 12.0pt;">OUTPUT:</span></u></b><b style="mso-bidi-font-weight: normal;"><u><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"></span></u></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-fareast-font-family: "Times New Roman";">SQL>
create table ajith(name varchar(10),rollno number(10),dept varchar(3));</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Table created.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> insert into ajith
values('&name','&rollno','&dept');</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for name: shalini</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for rollno: 11</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for dept: cse</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">old<span style="mso-spacerun: yes;">
</span>1: insert into ajith values('&name','&rollno','&dept')</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">new<span style="mso-spacerun: yes;">
</span>1: insert into ajith values('shalini','11','cse')</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">1 row created.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> insert into ajith
values('&name','&rollno','&dept');</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for name: anoshka</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for rollno: 12</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for dept: ece</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">old<span style="mso-spacerun: yes;">
</span>1: insert into ajith values('&name','&rollno','&dept')</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">new<span style="mso-spacerun: yes;">
</span>1: insert into ajith values('anoshka','12','ece')</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">1 row created.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> insert into ajith
values('&name','&rollno','&dept');</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for name: nive</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for rollno: 13</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Enter value for dept: eee</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">old<span style="mso-spacerun: yes;">
</span>1: insert into ajith values('&name','&rollno','&dept')</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">new<span style="mso-spacerun: yes;">
</span>1: insert into ajith values('nive','13','eee')</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">1 row created.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> desc ajith</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>Name<span style="mso-spacerun: yes;"> </span>Null?<span style="mso-spacerun: yes;"> </span>Type</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>------------------------------- -------- ----</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>NAME<span style="mso-spacerun: yes;">
</span>VARCHAR2(10)</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>ROLLNO<span style="mso-spacerun: yes;">
</span><span style="mso-spacerun: yes;"> </span>NUMBER(10)</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>DEPT<span style="mso-spacerun: yes;"> </span>VARCHAR2(3)</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> alter table ajith add(fees
number (5));</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Table altered.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> desc ajith</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>Name<span style="mso-spacerun: yes;"> </span>Null?<span style="mso-spacerun: yes;"> </span>Type</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>------------------------------- -------- ----</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>NAME<span style="mso-spacerun: yes;">
</span>VARCHAR2(10)</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>ROLLNO<span style="mso-spacerun: yes;"> </span>NUMBER(10)</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>DEPT<span style="mso-spacerun: yes;"> </span>VARCHAR2(3)</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";"><span style="mso-spacerun: yes;"> </span>FEES<span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> select * from ajith;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">NAME<span style="mso-spacerun: yes;"> </span>ROLLNO DEP<span style="mso-spacerun: yes;"> </span>FEES</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">---------- --------- --- ---------</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">shalini<span style="mso-spacerun: yes;"> </span>11 cse</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">anoshka<span style="mso-spacerun: yes;"> </span>12 ece</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">nive<span style="mso-spacerun: yes;"> </span>13 eee</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> update ajith set dept='cse'
where rollno=13;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">1 row updated.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> select * from ajith;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">NAME<span style="mso-spacerun: yes;"> </span>ROLLNO DEP<span style="mso-spacerun: yes;"> </span>FEES</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">---------- --------- --- ---------</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">shalini<span style="mso-spacerun: yes;"> </span>11 cse</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">anoshka<span style="mso-spacerun: yes;"> </span>12 ece</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">nive<span style="mso-spacerun: yes;"> </span>13 cse</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> delete from ajith where
name='nive';</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">1 row deleted.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> select * from ajith;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">NAME<span style="mso-spacerun: yes;"> </span>ROLLNO DEP<span style="mso-spacerun: yes;"> </span>FEES</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">---------- --------- --- ---------</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">shalini<span style="mso-spacerun: yes;"> </span>11 cse</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">anoshka<span style="mso-spacerun: yes;"> </span>12 ece</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> commit;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Commit complete.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> roll back;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Rollback complete.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> select * from ajith;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">NAME<span style="mso-spacerun: yes;"> </span>ROLLNO DEP<span style="mso-spacerun: yes;"> </span>FEES</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">---------- --------- --- ---------</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">shalini<span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>11 cse</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">anoshka<span style="mso-spacerun: yes;"> </span>12 ece</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> grant
select,insert,update,delete on ajith to public;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Grant succeeded.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> select * from ajith;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">NAME<span style="mso-spacerun: yes;"> </span>ROLLNO DEP<span style="mso-spacerun: yes;"> </span>FEES</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">---------- --------- --- ---------</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">shalini<span style="mso-spacerun: yes;"> </span>11 cse</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">anoshka<span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>12 ece</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> delete from ajith where
rollno=11;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">1 row deleted.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> select * from ajith;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">NAME<span style="mso-spacerun: yes;"> </span>ROLLNO DEP<span style="mso-spacerun: yes;"> </span>FEES</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">---------- --------- --- ---------</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">anoshka<span style="mso-spacerun: yes;"> </span>12 ece</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> revoke
select,insert,update,delete on ajith from public;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">Revoke succeeded.</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">SQL> select * from ajith;</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<br /></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">NAME<span style="mso-spacerun: yes;"> </span>ROLLNO DEP<span style="mso-spacerun: yes;"> </span>FEES</span></div>
<div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman";">---------- --------- --- ---------</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-fareast-font-family: "Times New Roman";">anoshka<span style="mso-spacerun: yes;"> </span>12<span style="mso-spacerun: yes;"> </span>ece</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"></span></div>
</div>Unknownnoreply@blogger.com0tag:blogger.com,1999:blog-2138855673652777881.post-48673528400911531922011-04-30T08:14:00.000+05:302011-04-30T08:14:11.309+05:30Data Definition Language(DDL) Commands in RDBMS<div dir="ltr" style="text-align: left;" trbidi="on">
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:TrackFormatting/>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DoNotPromoteQF/>
<w:LidThemeOther>EN-US</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndParaMark/>
<w:DontVertAlignCellWithSp/>
<w:DontBreakConstrainedForcedTables/>
<w:DontVertAlignInTxbx/>
<w:Word11KerningPairs/>
<w:CachedColBalance/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
<m:mathPr>
<m:mathFont m:val="Cambria Math"/>
<m:brkBin m:val="before"/>
<m:brkBinSub m:val="--"/>
<m:smallFrac m:val="off"/>
<m:dispDef/>
<m:lMargin m:val="0"/>
<m:rMargin m:val="0"/>
<m:defJc m:val="centerGroup"/>
<m:wrapIndent m:val="1440"/>
<m:intLim m:val="subSup"/>
<m:naryLim m:val="undOvr"/>
</m:mathPr></w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
DefSemiHidden="true" DefQFormat="false" DefPriority="99"
LatentStyleCount="267">
<w:LsdException Locked="false" Priority="0" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Normal"/>
<w:LsdException Locked="false" Priority="9" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="heading 1"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8"/>
<w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9"/>
<w:LsdException Locked="false" Priority="39" Name="toc 1"/>
<w:LsdException Locked="false" Priority="39" Name="toc 2"/>
<w:LsdException Locked="false" Priority="39" Name="toc 3"/>
<w:LsdException Locked="false" Priority="39" Name="toc 4"/>
<w:LsdException Locked="false" Priority="39" Name="toc 5"/>
<w:LsdException Locked="false" Priority="39" Name="toc 6"/>
<w:LsdException Locked="false" Priority="39" Name="toc 7"/>
<w:LsdException Locked="false" Priority="39" Name="toc 8"/>
<w:LsdException Locked="false" Priority="39" Name="toc 9"/>
<w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption"/>
<w:LsdException Locked="false" Priority="10" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Title"/>
<w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font"/>
<w:LsdException Locked="false" Priority="11" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtitle"/>
<w:LsdException Locked="false" Priority="22" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Strong"/>
<w:LsdException Locked="false" Priority="20" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Emphasis"/>
<w:LsdException Locked="false" Priority="59" SemiHidden="false"
UnhideWhenUsed="false" Name="Table Grid"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Placeholder Text"/>
<w:LsdException Locked="false" Priority="1" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="No Spacing"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 1"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 1"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 1"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 1"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 1"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 1"/>
<w:LsdException Locked="false" UnhideWhenUsed="false" Name="Revision"/>
<w:LsdException Locked="false" Priority="34" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="List Paragraph"/>
<w:LsdException Locked="false" Priority="29" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Quote"/>
<w:LsdException Locked="false" Priority="30" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Quote"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 1"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 1"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 1"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 1"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 1"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 1"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 1"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 1"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 2"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 2"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 2"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 2"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 2"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 2"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 2"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 2"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 2"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 2"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 2"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 2"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 2"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 2"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 3"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 3"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 3"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 3"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 3"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 3"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 3"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 3"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 3"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 3"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 3"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 3"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 3"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 3"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 4"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 4"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 4"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 4"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 4"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 4"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 4"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 4"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 4"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 4"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 4"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 4"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 4"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 4"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 5"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 5"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 5"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 5"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 5"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 5"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 5"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 5"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 5"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 5"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 5"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 5"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 5"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 5"/>
<w:LsdException Locked="false" Priority="60" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Shading Accent 6"/>
<w:LsdException Locked="false" Priority="61" SemiHidden="false"
UnhideWhenUsed="false" Name="Light List Accent 6"/>
<w:LsdException Locked="false" Priority="62" SemiHidden="false"
UnhideWhenUsed="false" Name="Light Grid Accent 6"/>
<w:LsdException Locked="false" Priority="63" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 1 Accent 6"/>
<w:LsdException Locked="false" Priority="64" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Shading 2 Accent 6"/>
<w:LsdException Locked="false" Priority="65" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 1 Accent 6"/>
<w:LsdException Locked="false" Priority="66" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium List 2 Accent 6"/>
<w:LsdException Locked="false" Priority="67" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 1 Accent 6"/>
<w:LsdException Locked="false" Priority="68" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 2 Accent 6"/>
<w:LsdException Locked="false" Priority="69" SemiHidden="false"
UnhideWhenUsed="false" Name="Medium Grid 3 Accent 6"/>
<w:LsdException Locked="false" Priority="70" SemiHidden="false"
UnhideWhenUsed="false" Name="Dark List Accent 6"/>
<w:LsdException Locked="false" Priority="71" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Shading Accent 6"/>
<w:LsdException Locked="false" Priority="72" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful List Accent 6"/>
<w:LsdException Locked="false" Priority="73" SemiHidden="false"
UnhideWhenUsed="false" Name="Colorful Grid Accent 6"/>
<w:LsdException Locked="false" Priority="19" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Emphasis"/>
<w:LsdException Locked="false" Priority="21" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Emphasis"/>
<w:LsdException Locked="false" Priority="31" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Subtle Reference"/>
<w:LsdException Locked="false" Priority="32" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Intense Reference"/>
<w:LsdException Locked="false" Priority="33" SemiHidden="false"
UnhideWhenUsed="false" QFormat="true" Name="Book Title"/>
<w:LsdException Locked="false" Priority="37" Name="Bibliography"/>
<w:LsdException Locked="false" Priority="39" QFormat="true" Name="TOC Heading"/>
</w:LatentStyles>
</xml><![endif]--><!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:"";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:"Times New Roman";
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:"Times New Roman";
mso-bidi-theme-font:minor-bidi;}
</style>
<![endif]-->
<br />
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">DDL
QUERIES:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>1.CREATE COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span><span style="mso-spacerun: yes;"> </span>Create table
tablename (column element fieldname column description);</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used to create a new table.</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>2.ALTER COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Alter table
tablename add on modify(column name datatypes size);</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used for adding the values and also for modifying the table.</span></div>
<a name='more'></a><br />
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>3.SELECT COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>Select * from tablename;</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>It is used for displaying the contents of the table</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12pt; line-height: 115%;">.</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>4.TRUNCATE COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Truncate table
tablename;</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>The contents of the table are deleted(truncate).</span></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>5.DROP COMMAND:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>Syntax:</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;"> </span>Drop table
tablename;</span></div>
<div class="MsoNormal">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;"><span style="mso-spacerun: yes;">
</span>The whole table ifself is delected.</span></div>
<div class="MsoNormal">
<br /></div>
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-ansi-language: EN-US; mso-bidi-language: AR-SA; mso-fareast-font-family: Calibri; mso-fareast-language: EN-US;"><br clear="all" style="page-break-before: always;" />
</span>
<div class="MsoNormal">
<b style="mso-bidi-font-weight: normal;"><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%;">OUTPUT:</span></b></div>
<div class="MsoNormal">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> create table robo(name
varchar(10),brand number(5));</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Table created.</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> desc robo</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>Name<span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>Null?<span style="mso-spacerun: yes;">
</span>Type</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>------------------------------- -------- ----</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>NAME<span style="mso-spacerun: yes;">
</span>VARCHAR2(10)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>BRAND<span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> insert into robo
values('&name','&brand');</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Enter value for name: priya</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Enter value for brand: 100</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">old<span style="mso-spacerun: yes;">
</span>1: insert into robo values('&name','&brand')</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">new<span style="mso-spacerun: yes;">
</span>1: insert into robo values('priya','100')</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">1 row created.</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> insert into robo
values('&name','&brand');</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Enter value for name: riya</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Enter value for brand: 1001</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">old<span style="mso-spacerun: yes;">
</span>1: insert into robo values('&name','&brand')</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">new<span style="mso-spacerun: yes;">
</span>1: insert into robo values('riya','1001')</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">1 row created.</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> insert into robo
values('&name','&brand');</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Enter value for name: supriya</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Enter value for brand: 10011</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">old<span style="mso-spacerun: yes;">
</span>1: insert into robo values('&name','&brand')</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">new<span style="mso-spacerun: yes;">
</span>1: insert into robo values('supriya','10011')</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">1 row created.</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> select * from robo;</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">NAME<span style="mso-spacerun: yes;"> </span>BRAND</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">---------- ---------</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">priya<span style="mso-spacerun: yes;"> </span>100</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">riya<span style="mso-spacerun: yes;"> </span>1001</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">supriya<span style="mso-spacerun: yes;"> </span>10011</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> alter table robo add(price
number(5));</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Table altered.</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> desc robo</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>Name<span style="mso-spacerun: yes;"> </span>Null?<span style="mso-spacerun: yes;"> </span>Type</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>------------------------------- -------- ----</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>NAME<span style="mso-spacerun: yes;">
</span>VARCHAR2(10)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>BRAND<span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>PRICE<span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> alter table robo modify(price
number(5));</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Table altered.</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> desc robo</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>Name<span style="mso-spacerun: yes;"> </span>Null?<span style="mso-spacerun: yes;"> </span>Type</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>------------------------------- -------- ----</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>NAME<span style="mso-spacerun: yes;">
</span>VARCHAR2(10)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>BRAND<span style="mso-spacerun: yes;">
</span><span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>PRICE<span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> truncate table robo;</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">Table truncated.</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> desc robo</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>Name<span style="mso-spacerun: yes;"> </span>Null?<span style="mso-spacerun: yes;"> </span>Type</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>------------------------------- -------- ----</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>NAME<span style="mso-spacerun: yes;">
</span><span style="mso-spacerun: yes;"> </span>VARCHAR2(10)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>BRAND<span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;"><span style="mso-spacerun: yes;"> </span>PRICE<span style="mso-spacerun: yes;"> </span>NUMBER(5)</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> select * from robo;</span></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">no rows selected</span></div>
<div class="MsoNormal" style="line-height: normal;">
<br /></div>
<div class="MsoNormal" style="line-height: normal;">
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt;">SQL> drop table robo;</span></div>
<span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; line-height: 115%; mso-ansi-language: EN-US; mso-bidi-language: AR-SA; mso-fareast-font-family: Calibri; mso-fareast-language: EN-US;">Table dropped.</span></div>Unknownnoreply@blogger.com0