<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-1031156110967948131</id><updated>2024-08-30T05:22:42.749-07:00</updated><category term="Concatenation"/><category term="(ADD"/><category term="BETWEEN Operator"/><category term="Case conversion functions"/><category term="Column Aliases"/><category term="Common Database structure"/><category term="Common Date Functions"/><category term="Comparing in sql"/><category term="Constraints"/><category term="Create and Alter Tables"/><category term="DATE Arithmetic"/><category term="DB Terms"/><category term="DECODE"/><category term="DESC"/><category term="Data type"/><category term="Duplict rows"/><category term="ELIMINATE DUPLICATE ROWS"/><category term="Entity Relationship model Components"/><category term="How to select columns and row"/><category term="In operator"/><category term="Is null operator"/><category term="LPAD"/><category term="Length"/><category term="Life Cycle"/><category term="Like"/><category term="Literal character"/><category term="Logical operators"/><category term="MODIFY"/><category term="NESTING"/><category term="NVL  "/><category term="Order by"/><category term="REMOVE)"/><category term="ROUND"/><category term="RPAD"/><category term="RULES OF PRIORITY"/><category term="Relatuion Concept"/><category term="SEQUENCES"/><category term="SORTING BY MULTIPLE COLUMNS"/><category term="SQL Functions"/><category term="SUBSTR and INSTR"/><category term="SYSDATE Function"/><category term="Single row functions"/><category term="Sorting by column alias"/><category term="TABLE STRUCTURE"/><category term="TO_CHAR"/><category term="TO_DATE"/><category term="TO_NUMBER"/><category term="Transaction control"/><category term="Type Of SQL Statement"/><category term="What is Arithmetic in SQL"/><category term="Where"/><category term="letiral as a separte column"/><title type='text'>Oracle SQL tutorial</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>36</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-3352160665356372358</id><published>2011-10-18T12:08:00.000-07:00</published><updated>2011-10-19T09:08:07.469-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="SEQUENCES"/><title type='text'>SEQUENCES</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;SEQUENCES&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You create a sequence to generate a unique numbers.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Create sequences&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can create a sequence by using CREATE SEQUENCE statement&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Create sequence for the EMPNO column of the NEWEMP table begin the sequence at 100,and maximum value at 1000.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;CREATE SEQUENCE NEWEMP_EMPNO&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;INCREMENT BY 1&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;START WITH 100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;MAXVALUE 1000;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;The INCREMENT BY option specifies the gap between sequence numbers &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;START WITH option specifies the first number in the sequence.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;MAXVALUE option specifies the maximum value the sequence can generate.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Other option not included in example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;NOMAXVALUE: a default maximum value&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;NOMAINVALUE: specific the minimum sequence value.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;CYCLE: cycle option specifies that the sequence continues to generate values.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;CACHE: specifies the number of values the server reallocates in memory&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/3352160665356372358/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sequences.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/3352160665356372358'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/3352160665356372358'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sequences.html' title='SEQUENCES'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-6413243974069109808</id><published>2011-10-17T08:55:00.000-07:00</published><updated>2011-10-19T10:42:15.669-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Transaction control"/><title type='text'>Transaction control</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;To complete your DML statements you need to control in it by&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;mso-list: l0 level1 lfo1; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;CMMIT: make all pending changes in a transaction permanent.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;mso-list: l0 level1 lfo1; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;ROLLBACK: discard pending changes and return to an earlier point in the statement.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;mso-list: l0 level1 lfo1; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;3-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SAVEPOINT: defines a marker to which you can later rollback.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Examples.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Commit&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;Suppose you inset new row in NEWEMP table and you want to save the latest changes&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Commit;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ROLLBACK&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
Suppose you inset new row in NEWEMP table and you want Returns the latest commit&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;Type&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; line-height: 18px;&quot;&gt;ROLLBACK;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;3-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SAVEPOINT&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
As the below example after inserting data you can create a named save point&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Insert into newemp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Select empno,ename,deptno&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;From emp&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;Where deptno=10;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SAVEPOINT inserting_finish;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can returned to the latest savepoint named inserting_finish&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ROLLBACK INSERTING_FINISH&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/6413243974069109808/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/transaction-control.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6413243974069109808'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6413243974069109808'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/transaction-control.html' title='Transaction control'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-8360109573933575533</id><published>2011-10-16T06:02:00.000-07:00</published><updated>2011-10-19T09:07:43.874-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="(ADD"/><category scheme="http://www.blogger.com/atom/ns#" term="MODIFY"/><category scheme="http://www.blogger.com/atom/ns#" term="REMOVE)"/><title type='text'>DML</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 115%;&quot;&gt;Manipulating Data&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 26px;&quot;&gt;Language&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 115%;&quot;&gt;&amp;nbsp;(DML)&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraph&quot;&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpFirst&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Before execute DML statements, you must have INSERT,UPDATE, and DELETE privilege.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;b&gt;  &lt;/b&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;INSERT EXAMPLES&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto; mso-list: l0 level1 lfo1; text-indent: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;INSERT INTO NEWEMP(EMPNO,ENAME,DEPTNO,SAL)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;VALUES (1800,’ASD’, 10, 900);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto; mso-list: l0 level1 lfo1; text-indent: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;INSERT INTO NEWEMP(EMPNO,ENAME,DEPTNO,SAL)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;VALUE (1600,NULL,10,100);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Be sure that before inserting null value in column check if it accepting null value or not.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;----&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can insert a special values like user name (must be as character data type) and SYSDATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Assume you want insert SYSDATE as using TO_DATE function to change a format &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Insert into EMP (ename, hiredate)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Values (‘MEGA’, TO_DATE (’01-JAN-2011 10:00’,’DD-MON-RR HH24: MI’), 20);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Copy data from another table using SUPUERY&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can insert data from another table using subquery &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Assume that you want copy data from dept =10 in emp table to a newemp table &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Insert into newemp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Select empno,ename,deptno&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;From emp &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Where deptno=10;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;UPDATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Also you can modify existing rows by using UPDATE statement .&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Assume that you want to change SMITH job and his salary &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Update EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Set job=’PROGRAMMER’, SAL=2500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WHERE ENAME=’SMITH’; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;-----------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;DELETE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can delete all rows in the table or delete one row or more by specifying a condition in the where clause rows.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Assume that we have TRAINING table including data for students &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;If you want delete all rows in table &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Delete from TRAINING;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;If you want delete specified row assume for trainer id =1700&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Delete from TRAINING &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Where TI=1700;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot; style=&quot;margin-left: 22.0pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;NOTE&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;: that if you want deletes row content a primary key referenced as a foreign key in another table the server not accepted.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraph&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/8360109573933575533/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/dml.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/8360109573933575533'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/8360109573933575533'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/dml.html' title='DML'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-4521761407133156016</id><published>2011-10-14T08:46:00.000-07:00</published><updated>2011-10-19T09:08:23.477-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Create and Alter Tables"/><title type='text'>Create and Alter Tables</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;Before create a tables please follow the below rules not for table only but for all database objects.&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto; mso-list: l1 level1 lfo1; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;All names begin with letters and contain no more than 30 characters.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto; mso-list: l1 level1 lfo1; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Names contain only the characters A-Z,a-z,0-9,underscore (_),$,#.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto; mso-list: l1 level1 lfo1; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;3-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can’t duplicate the name of another object in the same schema.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto; mso-list: l1 level1 lfo1; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;4-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Name can’t an oracle reserved word.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;To create table a user must have the create table privilege.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Steps to create table&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto; mso-list: l0 level1 lfo2; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Define a table name using&amp;nbsp; CREATE TABLE statement&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto; mso-list: l0 level1 lfo2; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Define a column names, datatype, and length.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;If you want define multiple columns, separate each column with a comma.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto; mso-list: l0 level1 lfo2; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;3-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Define constraints for the respective columns.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: .75in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;CREATE TABLE TRAINING&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;(T_NO&amp;nbsp; NUMBER(4)&amp;nbsp; CONSTRAINT TRAINING_T_NO_PK PRIMARY_KEY,T_NAME &amp;nbsp;VARACHAR2(25) CONSTRAINT TRAINING_T_NAME _NN NOT_NULL);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Result &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;TABLE CREATED&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------------------------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Create table based on another &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can create table based on another table using AS subquery clause within the create table statement.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;While create a table based on another table the second table maybe contain data this useful when creating a table to replace another similar table.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;If you want to create table based on another without data you need to use a condition in the where keywords. This condition must Non&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;-matching&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt; &lt;/span&gt;any data in second table &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Like &lt;span style=&quot;color: red;&quot;&gt;where 1=0&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Assume you want to select rows from EMP table and insert them in the new table &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Create table NEWEMP as select &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;EMPNO,ENAME,DEPTNO,SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;From EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Result&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;TABLE CREATED &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;If you want display data in a new table &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SELECT * FROM NEWEMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DEPTNO&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;------- ---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;800&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;30&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DEPTNO&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;------- ---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;950&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20 &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1300&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Assume that you want create structure only without data &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;CREATE TABLE NEWEMP2 AS &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SELECT * FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WHERE 1=0;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Since&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;&lt;span dir=&quot;RTL&quot; lang=&quot;AR-KW&quot;&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;&amp;nbsp; &lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;/span&gt;&amp;nbsp;1 not equal 0 then the new table created without data &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;If you want show the result &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;DESCRIBE NEWEMP2;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Name&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Null?&amp;nbsp;&amp;nbsp;&amp;nbsp; Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;----------------------------------------- -------- -------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;EMPNO&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; NOT NULL NUMBER (4)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;VARCHAR2 (10)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;VARCHAR2 (9)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;MGR&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;NUMBER (4)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;HIREDATE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;DATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;NUMBER (7,2)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;COMM&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;NUMBER (7,2)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;DEPTNO&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;NUMBER (2)&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: medium;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;--------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpFirst&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Alter tables&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;  &lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Some time you need to add column, modify column, redfine labels &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Add column&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;It used to add column to an existing table &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Suppose that you want add a new column for NEWEMP table this column named ABC&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Alter Table NEWEMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Add(ABC varchar2(20));&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;----------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Dropping column&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;If you want drop colum&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Alter table NEWEMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Drop ABC;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can also set column as unused by &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Typing&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Alter table NEWEMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;SET UNUSED ABC;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;YOU CAN DROP ALL UNUSED COLUMN &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;ALTER TABLE NEWEMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;DROUP UNUSED COLUMN;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;-----------------------------------------------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;MODIFYING COLUMN&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;to modify the column you need to used alter table statement and the MODIFY clause.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Also you can modify data type, default value, size, add or remove NOT NULL constraint.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;FOR EXAMPLE &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;ALTER TABLE NEWEMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;MODIFY (ABC VARCHAR2 (50));&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------------------------------------------------------------------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;TABLE DROPPING&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can drop table using DROP TABLE statement. While drop a table index for these table will be dropped&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can use THE CASCED CONSTRAINT option&amp;nbsp; if there are any referential constraint .&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;For Example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;DROP TABLE NEWEMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;CASCADE CONSTRAINTS;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;-------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;RENAMING TABLES&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can rename a table by using RENAME statement&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Syntax&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;RENAME old_name&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;To&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; new_name&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;RENAME newemp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;To&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; training;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;-------------------------------------------------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;TRUNCATE A TABLE &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Means that you can remove all the rows immediately without generating any rollback information&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Before using the TRUNCATE TABLE statement, you should disable any foreign key constraint.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;For example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;If you want remove rows from NEWEMP table &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Truncate table NEWEMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;---------------------------------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;COMMENT ON TABLE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can add or remove a comment on the table as a massage&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;For example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Type&amp;nbsp; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Comment on table TRAINING&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Is ‘content information about trainees people ’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;To remove a comment &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Comment on table TRAINING&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot; style=&quot;margin-left: 0in; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Is ‘’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/4521761407133156016/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/create-table.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/4521761407133156016'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/4521761407133156016'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/create-table.html' title='Create and Alter Tables'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-2075763658808438045</id><published>2011-10-13T11:28:00.000-07:00</published><updated>2011-10-19T09:08:39.390-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Constraints"/><title type='text'>Constraints</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Oracle uses constraints to prevent invalid data entry into a table.&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can add and remove constraint after creating a table.&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Constraints ensure that data in a table adhere to the recognized business rules.&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Referential integrity&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;In the foreign key establish a relationship between the data in the foreign key&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;column in the child table with data in the primary key column in the parent table.&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Constraint types.&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.75in; mso-add-space: auto;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 1in; mso-add-space: auto; mso-list: l0 level1 lfo1; text-indent: -0.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;ltr&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;NOT NULL: ensures the column always contains a value.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 1in; mso-add-space: auto; mso-list: l0 level1 lfo1; text-indent: -0.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;ltr&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;UNIQUE: ensures that a column contains unique values &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 1in; mso-add-space: auto; mso-list: l0 level1 lfo1; text-indent: -0.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;3-&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;ltr&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;PRIMARY KEY: column serves as the unique identifier for the table and is similar to a unique key, except that it cannot contain a NULL value. Table can have only one primary key.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 1in; mso-add-space: auto; mso-list: l0 level1 lfo1; text-indent: -0.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;4-&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;ltr&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FOREIGN KEY: it establishes a relationship between the child column and parent column.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot; style=&quot;margin: 0in 0in 10pt 1in; mso-add-space: auto; mso-list: l0 level1 lfo1; text-indent: -0.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;5-&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;ltr&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;CHECK: defines a condition that each row in a table must satisfy.&lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;ltr&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;strong&gt;&lt;span style=&quot;font-size: small;&quot;&gt;COLUMN –LEVEL CONSTRAINT&lt;/span&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;It references a single column and is defined within the specifications of the column that it constrains.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Not null constrain is must be defined at the column level.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;strong&gt;&lt;span style=&quot;font-size: small;&quot;&gt;TABLE - LEVEL CONSTRAINT&lt;/span&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Defined after the definitions of the columns and references one or more columns. All constraint can be defined to a table level exclude NOT NULL constrain defined at a column level&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;.you can disable a constraint without removing it.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;When you create constraint is important to name the constraint&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot; style=&quot;margin: 0in 0in 10pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;at the time you create it otherwise the server assign it a name.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpFirst&quot; style=&quot;margin: 0in 0in 0pt 38.5pt; mso-add-space: auto;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Add Constraints&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;By using alter table with ADD CONSTRAINT clause you can add constraint to an offered table.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;Not : &lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;before add constraint view &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;For example&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;ALTER TABLE NEWEMP&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;ADD CONSTRAINT newemp_abc_pk&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;PRIMARY KEY (ABC);&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;----------------------------------------------------------------&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;DROP CONSTRAINT&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;By using ALTER TABLE statement you can drop constraint &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;For example&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;ALTER TABLE NEWEMP&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;DROP CONSTRAINT newemp_abc_pk;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;If you want drop primary key you don’t need to determine constraint name you can write PRIMARY KEY only.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;CASCADE &lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;The optional cascade disables all dependent integrity constraints. that option applies to PRIMARY KEY constraints. &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;It causes the dependent FOREIGN.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;For example &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;ALTER TABLE DEPT&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Disable &amp;nbsp;CONSTRAINT DEPTNO&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;Cascade;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;If you enable the primary key, the foreign key is not automatic r-enabled you must re-enable the foreign key in a separate alter table statement. &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;--------------&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;HOW TO ENABLE CONSTRAINT&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;You can enable constraint after disabled it by ALTER TABLE statement.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;For example &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;ALTER TABLE DEPT&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 33pt; mso-add-space: auto; text-indent: -5.5pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;ENABLE &amp;nbsp;CONSTRAINT DEPTNO;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;margin: 0in 0in 0pt 0.5in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraph&quot; style=&quot;margin: 0in 0in 10pt; mso-add-space: auto;&quot;&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/2075763658808438045/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/constraints.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2075763658808438045'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2075763658808438045'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/constraints.html' title='Constraints'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-9095145510013601076</id><published>2011-10-12T11:11:00.000-07:00</published><updated>2011-10-12T11:20:39.319-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Common Database structure"/><title type='text'>Common Database structure</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 19px; line-height: 21px;&quot;&gt;Common Database structure&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;ListParagraphCxSpFirst&quot; style=&quot;text-align: justify; text-indent: -0.25in;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Times New Roman&#39;; font-size: medium;&quot;&gt;1-&lt;/span&gt;&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Times New Roman&#39;; font-size: medium;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;Table: Common structure in database is a table .table consist of columns and rows in which data is stored .the intersection of a column and&amp;nbsp; a row is called a field.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;text-align: justify; text-indent: -0.25in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;View: a view is a logical symbol of subsets of data from one or more database table. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;text-align: justify; text-indent: -0.25in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;3-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;Sequence: generate unique numbers. You can it to generate Primary key&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpMiddle&quot; style=&quot;text-align: justify; text-indent: -0.25in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;4-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;Synonym: alternate names for tables or for other database object &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;ListParagraphCxSpLast&quot; style=&quot;text-align: justify; text-indent: -0.25in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;5-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;Index: by using the index object you improve the performance of queries.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;Note: that you can create and modify table structures while database in used.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/9095145510013601076/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/common-database-structure.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/9095145510013601076'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/9095145510013601076'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/common-database-structure.html' title='Common Database structure'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-1418516674535533941</id><published>2011-10-03T12:44:00.000-07:00</published><updated>2011-10-19T09:09:15.853-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Common Date Functions"/><title type='text'>Common Date Functions</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #0066cc; font-family: arial, helvetica, sans-serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 12px; line-height: 16px;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #0066cc; font-family: arial, helvetica, sans-serif;&quot;&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span dir=&quot;LTR&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; color: black; font-family: Arial; font-size: 9pt;&quot;&gt;DATE FUNCTION IN SQL&lt;/span&gt;&lt;/span&gt;&lt;span lang=&quot;AR-KW&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1- MONTHS_BETWEEN Function : finds the number of months between two dates&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example&amp;nbsp; assume that you want find number of months between an employee hire date &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;And sysdate&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Select empno,ename,sal,hiredate,MONTHS_BETWEEN(’03-OCT-11’,HIREDATE)&amp;nbsp; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FROM EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&amp;nbsp; MONTHS_BETWEEN(&#39;03-OCT-11&#39;,HIREDATE)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;--------- ---------- ---------- --------- ------------------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800 17-DEC-80&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;369.548387&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600 20-FEB-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 367.451613&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 22-FEB-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 367.387097&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975 02-APR-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 366.032258&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 28-SEP-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 360.193548&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850 01-MAY-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 365.064516&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450 09-JUN-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 363.806452&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 19-APR-87&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 293.483871&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000 17-NOV-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 358.548387&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500 08-SEP-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 360.83871&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100 23-MAY-87&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 292.354839&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&amp;nbsp; MONTHS_BETWEEN(&#39;03-OCT-11&#39;,HIREDATE)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;--------- ---------- ---------- --------- ------------------------------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950 03-DEC-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;358&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 03-DEC-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 358&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300 23-JAN-82&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 356.354839&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 0cm; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;A DD_MONTHS function :by using these function you can adds a number of calendar month to a specified date.&lt;span style=&quot;color: #0070c0;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Select empno,ename,sal,hiredate,ADD_MONTHS (HIREDATE,7)&amp;nbsp; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FROM EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&amp;nbsp; ADD_MONTH&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;------ ---------- ---------- --------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800 17-DEC-80 17-JUL-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600 20-FEB-81 20-SEP-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 22-FEB-81 22-SEP-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975 02-APR-81 02-NOV-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 28-SEP-81 28-APR-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850 01-MAY-81 01-DEC-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450 09-JUN-81 09-JAN-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 19-APR-87 19-NOV-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000 17-NOV-81 17-JUN-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500 08-SEP-81 08-APR-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100 23-MAY-87 23-DEC-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&amp;nbsp; ADD_MONTH&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;------ ---------- ---------- --------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950 03-DEC-81 03-JUL-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 03-DEC-81 03-JUL-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300 23-JAN-82 23-AUG-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;2-NEXT DAY function : by using these function you can return the date of next day.&lt;span style=&quot;color: #0070c0;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Select empno, ename, NEXT_DAY (’03-OCT-2011’,’Friday’) Friday&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;From emp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;select next_day(&#39;03-oct-2011&#39;,&#39;friday&#39;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;from dual&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;NEXT_DAY(&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;07-OCT-11&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;3- LAST_DAY function : you can finds the date of the last day of month&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;select last_day(&#39;01-oct-2011&#39;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;from dual;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;LAST_DAY(&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;31-OCT-11&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 21px;&quot;&gt;3- ROUND And TRUNC function&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 21px;&quot;&gt;ROUND returns a date rounded to the unit specified, TURANC returns a date truncated to the unit specified.&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 21px;&quot;&gt;For example&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; line-height: 21px;&quot;&gt;SELECT ENAME,HIREDATE,&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; line-height: 21px;&quot;&gt;ROUND (HIREDATE,’MONTH’),&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;TRUNC(HIREDATE,’MONTH’)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FROM EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HIREDATE&amp;nbsp; ROUND(HIR TRUNC(HIR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------- --------- --------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 17-DEC-80 01-JAN-81 01-DEC-80&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20-FEB-81 01-MAR-81 01-FEB-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 22-FEB-81 01-MAR-81 01-FEB-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02-APR-81 01-APR-81 01-APR-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 28-SEP-81 01-OCT-81 01-SEP-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01-MAY-81 01-MAY-81 01-MAY-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 09-JUN-81 01-JUN-81 01-JUN-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 19-APR-87 01-MAY-87 01-APR-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 17-NOV-81 01-DEC-81 01-NOV-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 08-SEP-81 01-SEP-81 01-SEP-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 23-MAY-87 01-JUN-87 01-MAY-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HIREDATE&amp;nbsp; ROUND(HIR TRUNC(HIR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------- --------- --------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 03-DEC-81 01-DEC-81 01-DEC-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 03-DEC-81 01-DEC-81 01-DEC-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 23-JAN-82 01-FEB-82 01-JAN-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/1418516674535533941/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/common-date-functions.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/1418516674535533941'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/1418516674535533941'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/common-date-functions.html' title='Common Date Functions'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-5830885045398461324</id><published>2011-10-03T12:31:00.000-07:00</published><updated>2011-10-03T12:31:28.564-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="DATE Arithmetic"/><title type='text'>DATE Arithmetic</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;By using arithmetic operators you can perform calculations on dates.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SELECT EMPNO,ENAME,SAL,HIREDATE,HIREDATE+100 “NEW DATE”&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FROM EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;EMPNO ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;SAL HIREDATE&lt;span&gt;&amp;nbsp; &lt;/span&gt;NEW DATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;---------- ---------- ---------- --------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;7369 SMITH&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;800 17-DEC-80 27-MAR-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;7499 ALLEN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1600 20-FEB-81 31-MAY-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;7521 WARD&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1250 22-FEB-81 02-JUN-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;7566 JONES&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2975 02-APR-81 11-JUL-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;7654 MARTIN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1250 28-SEP-81 06-JAN-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;7698 BLAKE&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2850 01-MAY-81 09-AUG-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;7782 CLARK&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2450 09-JUN-81 17-SEP-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;7788 SCOTT&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;3000 19-APR-87 28-JUL-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;7839 KING&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;5000 17-NOV-81 25-FEB-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;7844 TURNER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1500 08-SEP-81 17-DEC-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;7876 ADAMS&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;1100 23-MAY-87 31-AUG-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;EMPNO ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;SAL HIREDATE&lt;span&gt;&amp;nbsp; &lt;/span&gt;NEW DATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;---------- ---------- ---------- --------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7900 JAMES&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;950 03-DEC-81 13-MAR-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7902 FORD&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;3000 03-DEC-81 13-MAR-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7934 MILLER &lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;1300 23-JAN-82 03-MAY-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Example2: Assume that you want numbers of weeks for each employee are worked for the company&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SELECT EMPNO,ENAME,HIREDATE,(SYSDATE-HIREDATE)/7 WEEKS_AMMOUNT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FROM EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;EMPNO ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;HIREDATE&lt;span&gt;&amp;nbsp; &lt;/span&gt;WEEKS_AMMOUNT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;------- ---------- --------- -------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7369 SMITH&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;17-DEC-80&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1606.80078&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7499 ALLEN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;20-FEB-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1597.51507&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7521 WARD&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;22-FEB-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1597.22935&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7566 JONES&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;02-APR-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1591.65792&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7654 MARTIN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;28-SEP-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1566.08649&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7698 BLAKE&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;01-MAY-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1587.51507&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7782 CLARK&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;09-JUN-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1581.94364&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7788 SCOTT&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;19-APR-87&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1276.22935&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7839 KING&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;17-NOV-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1558.94364&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7844 TURNER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;08-SEP-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1568.94364&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7876 ADAMS&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;23-MAY-87&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1271.37221&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;EMPNO ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;HIREDATE&lt;span&gt;&amp;nbsp; &lt;/span&gt;WEEKS_AMMOUNT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;------- ---------- --------- -------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7900 JAMES&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;03-DEC-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1556.65792&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7902 FORD&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;03-DEC-81&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1556.65792&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7934 MILLER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;23-JAN-82&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1549.37221&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/5830885045398461324/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/date-arithmetic.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/5830885045398461324'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/5830885045398461324'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/date-arithmetic.html' title='DATE Arithmetic'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-7013223995071008476</id><published>2011-10-03T12:27:00.000-07:00</published><updated>2011-10-03T12:27:16.274-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="SYSDATE Function"/><title type='text'>SYSDATE Function</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Is a date function returns the current date &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;The default format is DD-MON-YY&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;If you want to select current date &lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Type &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Select sysdate &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;From dual;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SYSDATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 14.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 14.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 14.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;03-OCT-11&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 14pt; line-height: 115%;&quot;&gt;-----------------------------------------------------------&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Dual is a dummy table. The dual table consists one column name DUMMY and one row containing the value X.&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #0070c0; font-size: 14pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 14.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/7013223995071008476/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sysdate-function.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/7013223995071008476'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/7013223995071008476'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sysdate-function.html' title='SYSDATE Function'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-6022656623992398320</id><published>2011-10-02T12:34:00.000-07:00</published><updated>2011-10-02T12:51:38.216-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Case conversion functions"/><title type='text'>Case conversion functions</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-ansi-language: EN-US; mso-bidi-language: AR-KW; mso-fareast-font-family: Calibri; mso-fareast-language: EN-US;&quot;&gt;Case conversion function used to display character values in a different case,without changing the case of the data in the table&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;Types of case conversion function&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &#39;Times New Roman&#39;;&quot;&gt;&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;1-&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 115%;&quot;&gt; &amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;UPPER: that display all characters in lowercase&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span dir=&quot;LTR&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;2-&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&lt;span&gt;&lt;span style=&quot;font: 7.0pt &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;LOWER: displays all character in lowercase.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;3-&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;INITCAP: converts the first letter or each word to uppercase and the remaining litters to lowercase.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;Syntax of Case Conversion Function&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;First you type the keyword then the character data that you want to convert, enclosed in parentheses.&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;Examples&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; font-size: 16px; line-height: 18px;&quot;&gt;SELECT&lt;span&gt;&amp;nbsp; &lt;/span&gt;LOWER(ENAME) EMPLOYEE&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; font-size: 16px; line-height: 18px;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;smith&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;allen&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ward&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;jones&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;martin&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;blake&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;clark&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;scott&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;king&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;turner&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;adams&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;james&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ford&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;miller&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SELECT&lt;span&gt;&amp;nbsp; &lt;/span&gt;UPPER(ENAME) EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FROM EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SMITH&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ALLEN&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;WARD&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;JONES&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;MARTIN&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;BLAKE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;CLARK&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SCOTT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;KING&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;TURNER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ADAMS&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;JAMES&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FORD&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;MILLER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SELECT&lt;span&gt;&amp;nbsp; &lt;/span&gt;INITCAP(ENAME) EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FROM EMP;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Smith&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Allen&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Ward&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Jones&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Martin&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Blake&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Clark&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Scott&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;King&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Turner&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Adams&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;EMPLOYEE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;James&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Ford&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Miller&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Case conversion functions used in the WHERE clause&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;FOR EXAMPLE CHECK THE DIFFERNET IN BELOW&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SELECT ENAME &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FROM EMP &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Where ename=’adams’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;no rows selected&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SELECT ENAME &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FROM EMP &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Where &lt;/span&gt;&lt;span style=&quot;color: #7030a0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;lower&lt;/span&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;(ename)=’adams’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ENAME&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: #0070c0;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;ADAMS&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-ansi-language: EN-US; mso-bidi-language: AR-KW; mso-fareast-font-family: Calibri; mso-fareast-language: EN-US;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 54.0pt; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 115%;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 54.0pt; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 115%;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 54.0pt; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 54pt; text-align: left; text-indent: -18pt;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/6022656623992398320/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/case-conversion-functions.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6022656623992398320'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6022656623992398320'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/case-conversion-functions.html' title='Case conversion functions'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-2844257735578419374</id><published>2011-10-02T12:25:00.000-07:00</published><updated>2011-10-12T10:47:10.203-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="DECODE"/><category scheme="http://www.blogger.com/atom/ns#" term="Length"/><category scheme="http://www.blogger.com/atom/ns#" term="LPAD"/><category scheme="http://www.blogger.com/atom/ns#" term="NESTING"/><category scheme="http://www.blogger.com/atom/ns#" term="NVL  "/><category scheme="http://www.blogger.com/atom/ns#" term="ROUND"/><category scheme="http://www.blogger.com/atom/ns#" term="RPAD"/><category scheme="http://www.blogger.com/atom/ns#" term="Single row functions"/><category scheme="http://www.blogger.com/atom/ns#" term="SQL Functions"/><category scheme="http://www.blogger.com/atom/ns#" term="SUBSTR and INSTR"/><category scheme="http://www.blogger.com/atom/ns#" term="TO_CHAR"/><category scheme="http://www.blogger.com/atom/ns#" term="TO_DATE"/><category scheme="http://www.blogger.com/atom/ns#" term="TO_NUMBER"/><title type='text'>SQL Functions</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 21px;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Single row function accepts one or more arguments and returns one value for each row.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;A single row functions can be used in SELECT, WHERE, and ORDER BY&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Also single functions can be nested&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Types of single row functions&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;1-&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;Number functions: accept numeric input and return numeric values.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;2-&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;Character functions: accept character input&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;3-&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;Date functions :accept date values&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;4-&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;Data type conversion: convert a value from one data type to another.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;5-&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;General functions: improve the power of your SQL statement. this category includes an important function to replace with an actual value If a column is NULL, and another powerful function to run queries based on conditional, IF –THEN-ELSE logic.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;---------------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 13pt;&quot;&gt;Single row functions&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;S &amp;nbsp; &amp;nbsp;Single row function accepts one or more arguments and returns one value for each row.&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;A &amp;nbsp; &amp;nbsp;single row functions can be used in SELECT, WHERE, and ORDER BY&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Al &amp;nbsp; so single functions can be nested&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;T &amp;nbsp; &amp;nbsp; types of single row functions&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;1-&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 7pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;apple-converted-space&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 7pt;&quot;&gt;&amp;nbsp;&lt;/span&gt;1-&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Number functions: accept numeric input and return numeric values.&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;2-&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 7pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;apple-converted-space&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 7pt;&quot;&gt;&amp;nbsp;&lt;/span&gt;2-&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Character functions: accept character input&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;3-&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;3-&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Date functions :accept date values&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;4-&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;4-&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Data type conversion: convert a value from one data type to another.&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;5-&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 7pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;apple-converted-space&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 7pt;&quot;&gt;&amp;nbsp;&lt;/span&gt;5-&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;General functions: improve the power of your SQL statement. this category includes an important function to replace with an actual value If a column is NULL, and another powerful function to run queries based on conditional, IF –THEN&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &#39;\&#39;Times New Roman\&#39;&#39;;&quot;&gt;-&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;ELSE logic&lt;/span&gt;&lt;span style=&quot;color: black; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 12pt;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; ----------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div dir=&quot;rtl&quot; style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in; text-align: left; text-indent: -0.25in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp; &amp;nbsp;TO_CHAR string&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;b&gt;  &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;TO_CHAR function converts a number or date to AVARCHAR2&amp;nbsp; in a format that you specify.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;TO_CHAR with date&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;You can use the TO_CHAR function to convert a date from the default data format to a format that you identify.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;The default format is DD-MON-YY .if you need to change the default format then you can use the TO_CHAR function to convert a date into a new format.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno,ename,to_char(hiredate,’dd/mm/yyyy’) “JOIN DATE”&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOIN DATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- ---------- ----------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 17/12/1980&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20/02/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 22/02/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02/04/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 28/09/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01/05/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7782 &lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 09/06/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 19/04/1987&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 17/11/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 08/09/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7876 &lt;st1:place w:st=&quot;on&quot;&gt;ADAMS&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 23/05/1987&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOIN DATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- ---------- ----------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 03/12/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 03/12/1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 23/01/1982&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno,ename,to_char(hiredate,’DD&amp;nbsp; MONTH&amp;nbsp;&amp;nbsp; YYYY’) “JOIN DATE”&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOIN DATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;-------- ---------- --------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 17&amp;nbsp; DECEMBER&amp;nbsp;&amp;nbsp;&amp;nbsp; 1980&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&amp;nbsp; FEBRUARY&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 22&amp;nbsp; FEBRUARY&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02&amp;nbsp; APRIL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 28&amp;nbsp; SEPTEMBER&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01&amp;nbsp; MAY&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7782 &lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 09&amp;nbsp; JUNE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 19&amp;nbsp; APRIL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1987&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 17&amp;nbsp; NOVEMBER&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 08&amp;nbsp; SEPTEMBER&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7876 &lt;st1:place w:st=&quot;on&quot;&gt;ADAMS&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 23&amp;nbsp; MAY&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1987&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOIN DATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;-------- ---------- --------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 03&amp;nbsp; DECEMBER&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 03&amp;nbsp; DECEMBER&amp;nbsp;&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 23&amp;nbsp; JANUARY&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1982&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;ALSO THE SEE BELOW EXAMPLE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno,ename,to_char(hiredate,’FMDAY , DD MONTH&amp;nbsp;&amp;nbsp; YYYY’) “JOIN DATE”&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOIN DATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------- ---------- ------------------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WEDNESDAY , 17 DECEMBER&amp;nbsp;&amp;nbsp; 1980&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FRIDAY , 20 FEBRUARY&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SUNDAY , 22 FEBRUARY&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; THURSDAY , 2 APRIL&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MONDAY , 28 SEPTEMBER&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FRIDAY , 1 MAY&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7782 &lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TUESDAY , 9 JUNE&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SUNDAY , 19 APRIL&amp;nbsp;&amp;nbsp; 1987&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TUESDAY , 17 NOVEMBER&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TUESDAY , 8 SEPTEMBER&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7876 &lt;st1:place w:st=&quot;on&quot;&gt;ADAMS&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SATURDAY , 23 MAY&amp;nbsp;&amp;nbsp; 1987&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOIN DATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------- ---------- ------------------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; THURSDAY , 3 DECEMBER&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; THURSDAY , 3 DECEMBER&amp;nbsp;&amp;nbsp; 1981&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SATURDAY , 23 JANUARY&amp;nbsp;&amp;nbsp; 1982&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;TO_CHAR with number&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;You can use the TO_CHAR function to convert other datatype values to characters.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;To display employee salaries&amp;nbsp; with $ (dollar sign)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno,ename,TO_CHAR(sal,’$99,999’)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;From emp&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Where empno=7499&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TO_CHAR(&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------- ---------- --------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp; 7499 ALLEN &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; $1,600&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;------------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;b&gt;TO_NUMBER&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;To convert a character string to a number ,you use the TO_NUMBER&amp;nbsp; function&lt;span dir=&quot;RTL&quot; lang=&quot;AR-SA&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno,ename,sal&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;From&amp;nbsp; emp&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Where sal &amp;gt; TO_NUMBER (‘$1,600’,’$9,999’);&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------ ---------- ----------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7782 &lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;-----------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;TO_DATE function&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;SQL DATE FUNCTION&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt; Used to convert a character string to a date format.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Assume that you have a character string on behalf of a date value. With format February &amp;nbsp;20, 1981. If you want compare this character string to a date value .you will receive a error&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Then you must used TO_DATE function to convert the character string into a date value.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;TYPE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SELECT EMPNO,ENAME,HIREDATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;WHERE HIREDATE = TO_DATE(‘February&amp;nbsp; 20, 1981’,’MONTH&amp;nbsp; DD,YYYY’);&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HIREDATE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------ ---------- ---------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20-FEB-81&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;See below links&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;a href=&quot;http://oracle-sql-tutorials.blogspot.com/2011/10/sysdate-function.html&quot;&gt;SYSDATE Function&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;a href=&quot;http://oracle-sql-tutorials.blogspot.com/2011/10/date-arithmetic.html&quot;&gt;DATE Arithmetic&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;http://oracle-sql-tutorials.blogspot.com/2011/10/common-date-functions.html&quot;&gt;Common Date Functions &lt;/a&gt;&lt;br /&gt;
-----------------------------------------------------------------------------------------------&lt;br /&gt;
&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;LPAD Function&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;L &amp;nbsp; &amp;nbsp;&lt;/span&gt;&lt;/b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;By using the LPAD function you can place a character or characters on the left of a character value.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;In the LPAD function syntax, you specify the name of the column that you want to pad&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;If you want pad employee names with&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&amp;nbsp;percentage&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;‘%’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;select ename,LPAD(ename,8,’%’)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;from emp;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;LPAD(ENA&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- --------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%SMITH&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%ALLEN&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%%WARD&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%JONES&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%MARTIN&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%BLAKE&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%&lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%SCOTT&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%%KING&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%TURNER&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%&lt;st1:place w:st=&quot;on&quot;&gt;ADAMS&lt;/st1:place&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;LPAD(ENA&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- --------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%JAMES&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%%%FORD&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;%%MILLER&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;------------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: &#39;Times New Roman&#39;;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;RPAD function&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;R &amp;nbsp; &lt;/span&gt;&lt;/b&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;RPAD function it use a same Logic for LPAD&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;apple-converted-space&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp;the different is RPAD function pads the character value on the right&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;select ename,RPAD(ename,8,’%’)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;from emp;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;RPAD(ENA&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- --------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;SMITH%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&amp;nbsp;&amp;nbsp;ALLEN%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;WARD%%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;JONES%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;MARTIN%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;BLAKE%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;SCOTT%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;KING%%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;TURNER%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;st1:place w:st=&quot;on&quot;&gt;ADAMS&lt;/st1:place&gt;%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;RPAD(ENA&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- --------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;JAMES%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;FORD%%%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;MILLER%%&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;-----------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;br /&gt;
&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Length Function&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;You used length function to know the number of characters in a string (as a numeric value).&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;To show the number of character for each job&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SQL&amp;gt; select job,length(job)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;from emp;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;LENGTH(JOB)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;--------- -----------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ANALYST&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;PRESIDENT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;9&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;-----------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;SUBSTR and INSTR functions&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;That function used to display information about a value&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;SUBSTR FUNCTION&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;You can take out a string of a determined length using the SUBSTR function.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Using the SUBSTR function, you specify a character string followed by two numbers. The first number represents the character position from which to begin extracting, and the second number represents the number of characters that you want to extract.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Assume that you want cut the first two letters of&amp;nbsp; an employee’s last name&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select ename,SUBSTER(ENAME,1,2)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SU&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- --&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SM&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;st1:state w:st=&quot;on&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;AL&lt;/st1:place&gt;&lt;/st1:state&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WA&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JO&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MA&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; BL&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLARK&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CL&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SC&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; KI&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TU&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ADAMS&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AD&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SU&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: 11.0pt;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- --&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: 11.0pt;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JA&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: 11.0pt;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FO&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: 11.0pt;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MI&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: 11.0pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;INSTR function&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;By using INSTR function you can find the numeric position of a named character&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Also you specify a character string followed by the character for which you want the numeric position&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;The function returns a numeric value instead of the placement of the first happening of the individual letter&amp;nbsp;&amp;nbsp;&amp;nbsp; in the string.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Assume that you want know the position of the first S in each employee name.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Then type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SELECT ENAME,INSTR(ENAME,’S’)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; INSTR(ENAME,&#39;S&#39;)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- ----------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLARK&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ADAMS&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; INSTR(ENAME,&#39;S&#39;)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- ----------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;------------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: Arial;&quot;&gt;&lt;b&gt;ROUND function&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;R &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;By using the round function you can round a number to a specified number of decimal&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;The ROUND function .Accept numeric input and returns numeric values.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;If you don’t specify a number of decimal places, or if you specify a zero for the number of decimal places, then the values is rounded to the left of the decimal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;If you want to calculate an employee’s daily salary.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SELECT ENAME,ROUND (SAL*12/365,2)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;ROUND(SAL*12/365,2)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- -------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;26.3&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;52.6&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;41.1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;97.81&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;41.1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;93.7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLARK&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;80.55&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;98.63&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;164.38&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;49.32&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ADAMS&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;36.16&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;ROUND(SAL*12/365,2)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- -------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;31.23&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;98.63&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;42.74&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Note : that you can round the result to the nearest integer by not specifying a number of decimal places in the ROUND function.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;-----------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;b&gt;TRUNCATE&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;function&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; color: black; font-family: Arial;&quot;&gt;SQL Truncate&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;The SQL&amp;nbsp;TRUNCATE&lt;span class=&quot;apple-converted-space&quot;&gt;&lt;b&gt;&amp;nbsp;&lt;/b&gt;&lt;/span&gt;function .Accept numeric input and returns numeric values.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;You specify the TRUNC function keyword followed by the column or expression that you want to truncate and the number of decimal places to which you want to truncate in the result.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;If you don’t specify a number of decimal places, or if you specify a zero for the number of decimal places, then tha value is truncated to the integer. If you specify a negative number of decimal places, then values to the left of decimal place are truncated to zero.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Assume that you want to calculate an employee daialy salary as sal*12/365 and truncate the result to two decimal places.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SELECT ENAME,TRUNC (SAL*12/365,2)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TRUNC(SAL*12/365,2)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- -------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;26.3&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;52.6&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;41.09&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;97.8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;41.09&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;93.69&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLARK&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;80.54&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;98.63&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;164.38&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 49.31&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ADAMS&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;36.16&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TRUNC(SAL*12/365,2)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- -------------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;31.23&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;98.63&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 42.73&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;T&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;he result produces the rest of the first value divided by the second value.&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;For example assume that you want calculate the rest of salary divided by commission&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For employee number 7654&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;Type&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno,ename,sal,comm,mod(sal,comm)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;From emp&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Where empno= 7654 ;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;COMM MOD(SAL,COMM)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------- ---------- ---------- ---------- -------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1400&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1250&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;If you see the result you will find that the function returns the same salary value&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Because the comm value is larger than the salary value also if&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;comm. Equal zero the result it will be same first value(in our example sal)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Please check the below example for clarification&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno, ename, sal, comm, MOD (SAL, COMM)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;WHERE JOB =’SALESMAN’;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;COMM MOD(SAL,COMM)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- ---------- ---------- ---------- -------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1600&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;300&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;100&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;250&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1400&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1250&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;---------------------------------------------------------------------------------------------&lt;br /&gt;
&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;MOD function&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in; text-indent: -11pt;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&amp;nbsp; &amp;nbsp;The result produces the rest of the first value divided by the second value. &amp;nbsp;&lt;b&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in; text-indent: -11pt;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 12.0pt; mso-ansi-language: EN-US; mso-bidi-language: AR-SA; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-language: EN-US;&quot;&gt;&amp;nbsp; &amp;nbsp;For example assume that you want calculate the rest of salary divided by&amp;nbsp;&lt;/span&gt;&lt;/span&gt;commission&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in; text-indent: -11pt;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For employee number 7654&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Select empno,ename,sal,comm,mod(sal,comm)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;From emp&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;Where empno= 7654 ;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;COMM MOD(SAL,COMM)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------- ---------- ---------- ---------- -------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1400&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1250&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in; text-indent: -11pt;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial; font-size: 12.0pt; mso-ansi-language: EN-US; mso-bidi-language: AR-SA; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-language: EN-US;&quot;&gt;&amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;----------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Length Function&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;L &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;You used length function to know the number of characters in a string (as a numeric value).&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;To show the number of character for each job&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SQL&amp;gt; select job,length(job)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;from emp;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;LENGTH(JOB)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;--------- -----------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ANALYST&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;PRESIDENT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;9&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;8&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;LENGTH(JOB)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;--------- -----------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;5&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ANALYST&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&amp;nbsp;&amp;nbsp;7&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;5&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;------------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;NVL function&amp;nbsp;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;NVL SQL&amp;nbsp;used to convert a null value to an actual value.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;To convert null values in a numeric, character, or date . you must specify a return value that is a number , character ,or date&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;If you want to calculate annual compensation for all employees&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Type&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SELECT EMPNO,ENAME, SAL,COMM,(SAL*12)+NVL(COMM,0) Annual&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;FROM EMP;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; COMM&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ANNUAL&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------ ---------- ---------- ---------- ----------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;9600&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 300&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;19500&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 500&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;15500&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;35700&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1400&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 16400&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;34200&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7782 &lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;29400&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;36000&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;60000&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;18000&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7876 &lt;st1:place w:st=&quot;on&quot;&gt;ADAMS&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;13200&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;------------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;DECODE function&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;DECODE IN SQL&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;It a single – row function it do the work of&amp;nbsp; IF –THEN-ELSE . the DECODE function compares a column or expression to each search value.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;DECODE Syntax.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;DECOD (COLUMN_NAME, SEARCH1, RESULT1, SEARCH2, RESULT2)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;FOR EXAMPLE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;if you want calculate the salary increases by 10% for employees who working in department 20&amp;nbsp; using THE DECODE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;type&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SELECT EMPNO, ENAME,SAL,DEPTNO,DECODE(deptno,10,sal*1.1) “INCREMENT”&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;From emp;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DEPTNO&amp;nbsp; INCREMENT&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------ ---------- ---------- ---------- ----------&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;800&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7782 &lt;st1:place w:st=&quot;on&quot;&gt;CLARK&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2695&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;5500&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7876 &lt;st1:place w:st=&quot;on&quot;&gt;ADAMS&lt;/st1:place&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DEPTNO&amp;nbsp; INCREMENT&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;------ ---------- ---------- ---------- ----------&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&lt;/span&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;1300&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span class=&quot;apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&amp;nbsp;&amp;nbsp;1430&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;If you check the result you will find that only employees who working in department 10&amp;nbsp; get increment.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;------------------------------------------------------------------------------------------------------------------&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;NESTING Function&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;It used to create complex and flexible statements that retrieve exactly the data that you need. NESTING function it functions within functions.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;Assume that you want display how earn commission and who’s not by ‘NO COMMISSION’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;TYPE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;SELECT ENAME, NVL (TO_CHAR (COMM),’No commission’) earn_comm&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial;&quot;&gt;From emp;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EARN_COMM&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- ---------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 300&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;WARD&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;500&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1400&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;CLARK&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ADAMS&lt;/span&gt;&lt;/st1:place&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; EARN_COMM&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;---------- ---------------&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0.0001pt; margin-left: 0in; margin-right: 0in; margin-top: 0in;&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: Arial;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; No commission&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Arial; font-weight: bold;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in; text-indent: -.25in;&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: black; font-family: Arial;&quot;&gt;D&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/2844257735578419374/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sql-functions.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2844257735578419374'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2844257735578419374'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sql-functions.html' title='SQL Functions'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-5749459755450625378</id><published>2011-10-02T12:23:00.001-07:00</published><updated>2011-10-11T09:44:56.665-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="SORTING BY MULTIPLE COLUMNS"/><title type='text'>SORTING BY MULTIPLE COLUMNS</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;You can used more than one column to sort data by identify multiple columns in the ORDER BY clause.&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;FOR EXAMPLE &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;SELECT EMPNO,ENAME,JOB,DEPTNO&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;ORDER BY DEPTNO,JOB;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DEPTNO&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;-------- ---------- --------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;10&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; PRESIDENT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;10&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ANALYST&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;20&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ANALYST&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;20&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;20&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;20&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;30&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DEPTNO&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;-------- ---------- --------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;30&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/5749459755450625378/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sorting-by-multiple-columns.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/5749459755450625378'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/5749459755450625378'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sorting-by-multiple-columns.html' title='SORTING BY MULTIPLE COLUMNS'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-5449115219080934668</id><published>2011-10-02T12:22:00.000-07:00</published><updated>2011-10-02T12:22:22.845-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Sorting by column alias"/><title type='text'>Sorting by column alias</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;You can use the column alias if you want a more expressive title for data &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;For example&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;Select ename,sal,empno ,sal+100 &lt;span&gt;&amp;nbsp;&lt;/span&gt;bounce&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; font-size: 16px; line-height: 18px;&quot;&gt;Order by bounce;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;SAL&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;EMPNO&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;BOUNCE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;---------- ---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SMITH&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;800&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7369&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;900&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;JAMES&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;950&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7900&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1050&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ADAMS&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1100&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7876&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1200&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;WARD&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1250&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7521&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1350&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;MARTIN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1250&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7654&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1350&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;MILLER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1300&lt;span&gt;&amp;nbsp; &lt;/span&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;7934&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1400&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;TURNER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1500&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7844&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ALLEN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1600&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7499&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1700&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;CLARK&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2450&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7782&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2550&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;BLAKE&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2850&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7698&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2950&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;JONES&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2975&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7566&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;3075&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;SAL&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;EMPNO&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;BOUNCE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;---------- ---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SCOTT&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;3000&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7788&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;3100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;FORD&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;3000&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7902&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;3100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #0070c0; font-size: 16px; line-height: 18px;&quot;&gt;KING&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;5000&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7839&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;5100&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/5449115219080934668/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sorting-by-column-alias.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/5449115219080934668'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/5449115219080934668'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/sorting-by-column-alias.html' title='Sorting by column alias'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-1401445044854431199</id><published>2011-10-02T12:16:00.000-07:00</published><updated>2011-10-02T12:20:00.685-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="DESC"/><title type='text'>DESC Keyword</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;The default sort order is ascending when using the ORDER BY clause , you can reverse the order in which rows are displayed by using the DESC keywords. It placed after column name in the ORDER BY clause&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;For Example&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; line-height: 18px;&quot;&gt;SELECT EMPNO,ENAME&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;FROM EMP&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;ORDER BY SAL DESC;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #0070c0; line-height: 18px;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;  &lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;----- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;----- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7876 ADAMS&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;color: red;&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&amp;nbsp;7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: medium;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;Select ename,sal,mgr&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span style=&quot;color: #0070c0; line-height: 115%;&quot;&gt;  &lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;Order by mgr DESC;&lt;/b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: medium;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;SAL&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;MGR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #00b050; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;KING&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SMITH&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;800&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7902&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;JONES&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;2975&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7839&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;CLARK&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2450&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7839&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;BLAKE&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;2850&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7839&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ADAMS&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1100&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7788&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;MILLER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1300&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7782&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ALLEN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1600&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;MARTIN&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1250&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;WARD&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1250&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;JAMES&lt;span&gt;&amp;nbsp; &lt;/span&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;950&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;SAL&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;MGR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;TURNER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;1500&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &amp;quot;Times New Roman&amp;quot;; font-size: 12.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;SCOTT&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;3000&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7566&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;3000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7566&lt;b&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 14.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 14.0pt; line-height: 115%; mso-bidi-language: AR-KW;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/1401445044854431199/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/desc-keyword.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/1401445044854431199'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/1401445044854431199'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/desc-keyword.html' title='DESC Keyword'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-2007886130614506156</id><published>2011-10-02T12:07:00.000-07:00</published><updated>2011-10-02T13:25:47.900-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Order by"/><title type='text'>Order by</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;We used order by clause to sort rows in an order that you specify.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Sorting data is ascending order by .&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;1-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Numeric data is sorted from the lowest to the highest number. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;2-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Character data is sorted alphabetically from A to Z .&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;3-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Date data is sorted from the earliest to the latest date.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; mso-list: l0 level1 lfo1; text-indent: -18.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;4-&lt;span style=&quot;font: normal normal normal 7pt/normal &#39;Times New Roman&#39;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span dir=&quot;LTR&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Null values are displayed last for ascending sequences.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can use a column alias in an order by clause to sort information.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;You can sort data by expression.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Examples&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Select empno,ename,sal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Order by sal;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------ ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;950&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ------ ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt; text-align: justify;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;Select empno,ename,sal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;Order by ename;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;Select empno,ename,sal,hiredate&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp; From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp; Order by hiredate;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------ ---------- ---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800 17-DEC-80&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600 20-FEB-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 22-FEB-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975 02-APR-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850 01-MAY-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450 09-JUN-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500 08-SEP-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 28-SEP-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000 17-NOV-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950 03-DEC-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 03-DEC-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------ ---------- ---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300 23-JAN-82&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 19-APR-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100 23-MAY-87&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;Select empno,ename,sal,hiredate,sal*12&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;Order by sal*12;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL*12&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------- ---------- ---------- --------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800 17-DEC-80&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 9600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7900 JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950 03-DEC-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 11400&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100 23-MAY-87&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 13200&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7521 WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 22-FEB-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 15000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250 28-SEP-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 15000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7934 MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300 23-JAN-82&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 15600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500 08-SEP-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 18000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600 20-FEB-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 19200&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450 09-JUN-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 29400&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850 01-MAY-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 34200&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975 02-APR-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 35700&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL HIREDATE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL*12&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------- ---------- ---------- --------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 19-APR-87&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 36000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 03-DEC-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 36000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-left: 36.0pt;&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000 17-NOV-81&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 60000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;a href=&quot;http://oracle-sql-tutorials.blogspot.com/search/label/DESC&quot;&gt;DESC&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;a href=&quot;http://oracle-sql-tutorials.blogspot.com/search/label/Sorting%20by%20column%20alias&quot;&gt;Sorting by column alias&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;http://oracle-sql-tutorials.blogspot.com/search/label/SORTING%20BY%20MULTIPLE%20COLUMNS&quot;&gt;SORTING BY MULTIPLE COLUMNS&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/2007886130614506156/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/order-by.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2007886130614506156'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2007886130614506156'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/order-by.html' title='Order by'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-2640328341386525689</id><published>2011-10-02T12:02:00.000-07:00</published><updated>2011-10-02T12:02:48.390-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="RULES OF PRIORITY"/><title type='text'>RULES OF PRIORITY</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;IN SQL SELECT statement the oracle server evaluates comparison operator’s begor logival operators.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;In the evaluation of logical operators ,NOT is evaluated first,AND is evaluated second,and OR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Is evaluated third.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can override rules of precedence by using parentheses.&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: medium;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;For example&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;Select empno,ename,job&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;From&lt;span&gt;&amp;nbsp; &lt;/span&gt;emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;Where&lt;span&gt;&amp;nbsp; &lt;/span&gt;SAL =1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;AND (JOB&lt;span&gt;&amp;nbsp; &lt;/span&gt;=’SALESMAN’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;OR&lt;span&gt;&amp;nbsp; &lt;/span&gt;job&lt;span&gt;&amp;nbsp; &lt;/span&gt;=’CLERK’);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; line-height: 115%;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;EMPNO ENAME&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;JOB&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; line-height: 115%;&quot;&gt;--------- ---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; line-height: 115%;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;7844 TURNER&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;SALESMAN&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;The result lists employees who are either a CLERK or a SALESMAN and who earn more than $1500.&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: medium;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/2640328341386525689/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/rules-of-priority.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2640328341386525689'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/2640328341386525689'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/rules-of-priority.html' title='RULES OF PRIORITY'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-6079674411996148224</id><published>2011-10-02T11:59:00.000-07:00</published><updated>2011-10-11T08:40:34.251-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Logical operators"/><title type='text'>Logical operators</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;b&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span dir=&quot;LTR&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; font-family: &#39;Trebuchet MS&#39;;&quot;&gt;Logical operators&lt;/span&gt; in SQL&lt;/span&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span lang=&quot;AR-SA&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; font-family: Arial;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;b&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;br /&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; style=&quot;border-collapse: collapse; border: none; mso-border-alt: solid windowtext .5pt; mso-border-insideh: .5pt solid windowtext; mso-border-insidev: .5pt solid windowtext; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt; mso-yfti-tbllook: 1184;&quot;&gt;&lt;tbody&gt;
&lt;tr&gt;   &lt;td style=&quot;border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 148.2pt;&quot; width=&quot;198&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;And&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-left: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 392.55pt;&quot; width=&quot;523&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;Used to   define conditions that must all be true for a row to be retrieved.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr&gt;   &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 148.2pt;&quot; width=&quot;198&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;OR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 392.55pt;&quot; width=&quot;523&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;Used to   define two conditions of which only one must be true for a row to be   retrieved.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr&gt;   &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 148.2pt;&quot; width=&quot;198&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;NOT &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 392.55pt;&quot; width=&quot;523&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;You can use   the NOT operator to invert the result of single condition in the where   clause.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Examples.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;AND OPERATOR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Suppose you want to display the employee number and name and salary of all employees &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Who earn equal and more than 800$ and who are in department 20. Then you will write the next statement&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Select empno,ename,deptno,sal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;Where sal &amp;gt;=800 &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;And deptno=20;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&lt;span style=&quot;color: #1f497d;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; DEPTNO&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;------ ---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7369 SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;800&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7876 ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1100 &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;OR Operator &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Assume that &amp;nbsp;want to retrieve information about employees who earn a salary greater than or equal to $1250 or who have the job title SALESMAN&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;Then you can combine these conditions in a where clause by using the or operator.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SELECT ENAME,JOB,SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WHERE SAL &amp;gt;= 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;OR JOB =’ SALESMAN’;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------- --------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ALLEN&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;SALESMAN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WARD&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;SALESMAN&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;MANAGER&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;MARTIN&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;SALESMAN&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;MANAGER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ANALYST&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;PRESIDENT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;TURNER&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;SALESMAN&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;ANALYST&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;CLERK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;1300&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 21px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 21px;&quot;&gt;Notice that you can use the OR logical operator in combination with any comparison operator to specify conditions in a where clause.&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;NOT operator&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can use the NOT logical operator in combination with the comparison operators IN, BETWWEN, LIKE, AND IS NULL.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;To retrieve a list of employees who are not salesman,&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;president,&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;clerk&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You can use the not operator IN combination with the in operator.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; line-height: 21px;&quot;&gt;SQL&amp;gt; SELECT EMPNO,ENAME,JOB,SAL&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; WHERE JOB NOT IN (&#39;SALESMAN&#39;, &#39;PRESIDENT&#39;, &#39;CLERK&#39;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #1f497d;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JOB&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------- ---------- --------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;7566 JONES&amp;nbsp; &amp;nbsp; &amp;nbsp;MANAGER&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;MANAGER&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;MANAGER&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;ANALYST&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ANALYST&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;You place NOT directly before the IN,BETWEEN,and LIKE operators in a sql statement.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;However with the IS NULL operator ,you place the not keyword in the middle to produce the operator IS NOT NULL.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;EXAMPL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SELECT ENAME,SAL,JOB&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WHERE&amp;nbsp; JOB NOT LIKE &#39;SALESMAN&#39;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL JOB&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------- ---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 800 CLERK&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975 MANAGER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850 MANAGER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450 MANAGER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SCOTT&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;3000 ANALYST&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000 PRESIDENT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100 CLERK&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950 CLERK&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 ANALYST&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300 CLERK&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;EXAMPL: for NOT operator with NULL VALUES.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SELECT ENAME,MGR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WHERE MGR IS NOT NULL;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MGR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7902&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7839&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #1f497d; line-height: 18px;&quot;&gt;7839&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;CLARK&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;7839&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;SCOTT&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;7566&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;7788&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;JAMES&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;7698&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MGR&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;FORD&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;7566&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7782&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #1f497d; font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;13 rows selected.&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: medium;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/6079674411996148224/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/logical-operators.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6079674411996148224'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6079674411996148224'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/logical-operators.html' title='Logical operators'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-4685522376759086990</id><published>2011-10-02T11:53:00.000-07:00</published><updated>2011-10-11T09:45:39.955-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Is null operator"/><title type='text'>Is null operator</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span dir=&quot;LTR&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; color: black; font-family: Arial; font-size: 9pt;&quot;&gt;&lt;b&gt;COMPARE NULL IN SQL&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;If you want to find out if a column contains any null values, then you can use the is NULL operator in the where clause.&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: 21px;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;A null value means that the value is unavailable. You cannot test for null values using an equal sign, because a Null value cannot be equal for unequal any value.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: 21px;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;For example you want to retrieve the names of employees who do not have a manager . you can use the IS NULL operator to find all rows that contain a null value in the MGR column.&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: medium;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: 21px;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;line-height: 21px;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 14pt; line-height: 115%;&quot;&gt;SQL&amp;gt; select ename&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 14pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;from emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 14pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp;&amp;nbsp;where mgr is null;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 14pt; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;span style=&quot;color: #0070c0;&quot;&gt;ENAME&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 14pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 14pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; KING&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/4685522376759086990/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/is-null-operator.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/4685522376759086990'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/4685522376759086990'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/10/is-null-operator.html' title='Is null operator'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-225114795237895980</id><published>2011-09-29T08:44:00.000-07:00</published><updated>2011-10-11T08:45:35.500-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Like"/><title type='text'>LIKE</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;When&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;&amp;nbsp;you don’t know what value you need to search then you can use the like operator in where cluse.&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Symbols with like.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;(%) represents any number of characters&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;(_) the underscore symbol represents a single character.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;The search string is enclosed in single quotation marks.&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: white;&quot;&gt;sql wildcard&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;span lang=&quot;AR-KW&quot; style=&quot;color: white; mso-bidi-language: AR-KW;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;span lang=&quot;AR-KW&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;u&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Examples &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/u&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Select ename,job&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;From emp &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Where ename like ‘c%’;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Ename&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;job&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Clark&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; manager&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Select ename,job &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Where ename like ‘s%’;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Ename&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; job&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Smith&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; clerk&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Scott&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; analyst&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Sql&amp;gt; select ename &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 2&amp;nbsp; from emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 3&amp;nbsp; where ename like &#39;_a%&#39;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Ename&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Ward&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Martin&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;James&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;The result is a list of employee names .each name includes the letter a as the second letter in the name.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/225114795237895980/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/like.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/225114795237895980'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/225114795237895980'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/like.html' title='LIKE'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-3237612786751048154</id><published>2011-09-29T08:43:00.000-07:00</published><updated>2011-10-01T10:03:25.365-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="In operator"/><title type='text'>IN</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span style=&quot;font-family: Calibri; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;b&gt;IN&amp;nbsp;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: Calibri; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;IN Operator used to restrict rows retrieved to values in specified list &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;The IN keyword is followed by values separated by commas.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;The full list of values is enclosed within a single set of parentheses.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Also you can use IN with any data type&amp;nbsp; (character, numeric, dates).&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;For example &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Select empno,ename,sal &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;Where sal in (125,3000,1600);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;------ ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;SELECT ENAME,SAL,JOB&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;WHERE JOB IN (‘MANAGER’,’ANALYST’,’PRESIDENT’)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL JOB&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975 MANAGER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850 MANAGER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450 MANAGER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 ANALYST&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;KING&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;5000 PRESIDENT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: &#39;Times New Roman&#39;; font-size: 12pt; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000 ANALYST&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/3237612786751048154/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/3237612786751048154'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/3237612786751048154'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/in.html' title='IN'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-6718876577846753470</id><published>2011-09-29T08:39:00.001-07:00</published><updated>2011-10-11T09:47:15.582-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="BETWEEN Operator"/><title type='text'>BETWEEN</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;b&gt;BETWEEN&amp;nbsp;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div dir=&quot;LTR&quot; style=&quot;margin-bottom: .0001pt; margin: 0cm;&quot;&gt;&lt;st1:placename w:st=&quot;on&quot;&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span dir=&quot;LTR&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; color: black; font-family: Arial; font-size: 9pt;&quot;&gt;SQL&lt;/span&gt;&lt;/span&gt;&lt;/st1:placename&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span dir=&quot;LTR&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; color: black; font-family: Arial; font-size: 9pt;&quot;&gt; &lt;st1:placetype w:st=&quot;on&quot;&gt;RANGE&lt;/st1:placetype&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: arial, helvetica, sans-serif;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 12px; line-height: 16px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;used to display rows based on a rang of values,you use the between and keywords .&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div dir=&quot;LTR&quot; style=&quot;margin-bottom: .0001pt; margin: 0cm;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;You specify the between keyword followed by the lower limit of the range, and keyword, and the higher limit of the range.&lt;/span&gt;&lt;span style=&quot;color: black; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;br /&gt;
&lt;div dir=&quot;LTR&quot; style=&quot;margin-bottom: .0001pt; margin: 0cm;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;For example&lt;/span&gt;&lt;span style=&quot;color: black; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;SELECT&amp;nbsp; EMPNO,ENAME,SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;WHERE SAL BETWEEN 1600 AND 3000;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;--------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7499 ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7788 SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7902 FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-size: 12pt; line-height: 115%;&quot;&gt;WHEN YOU USE THE CHARACTER OR DATE VALUES WITH BETWEEN OPERATOR .YOU PLACE EACH VALUE WITHIN SINGLE QUOTATION MARKS.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-size: 12pt; line-height: 115%;&quot;&gt;FOR EXAMPLE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;SELECT EMPNO,ENAME,SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;WHERE HIREDATE&amp;nbsp; BETWEEN ’02-APR-81’ AND ’17-NOV-81’;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;EMPNO ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;--------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7566 JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7654 MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7698 BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7782 CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7839 KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7844 TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;SELECT ENAME, SAL &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;FROM EMP &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;WHERE ENAME BETWEEN ‘A’ AND ‘S’;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;MARTIN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2450&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;ADAMS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1100&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;JAMES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 950&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-size: 12pt; line-height: 115%;&quot;&gt;MILLER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1300&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/6718876577846753470/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/between.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6718876577846753470'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6718876577846753470'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/between.html' title='BETWEEN'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-6219026417833363709</id><published>2011-09-29T08:38:00.000-07:00</published><updated>2011-10-11T08:56:01.419-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Comparing in sql"/><title type='text'>Comparing Expression</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit; font-size: 16px; line-height: 18px;&quot;&gt;&lt;b&gt;Comparing in sql&amp;nbsp;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; style=&quot;border-collapse: collapse; border: none; mso-border-alt: solid windowtext .5pt; mso-border-insideh: .5pt solid windowtext; mso-border-insidev: .5pt solid windowtext; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt; mso-yfti-tbllook: 1184;&quot;&gt;&lt;tbody&gt;
&lt;tr&gt;   &lt;td style=&quot;border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.35pt;&quot; valign=&quot;top&quot; width=&quot;360&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;&lt;span dir=&quot;RTL&quot; lang=&quot;AR-KW&quot; style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;=&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-left: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.4pt;&quot; valign=&quot;top&quot; width=&quot;361&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Equal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr&gt;   &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.35pt;&quot; valign=&quot;top&quot; width=&quot;360&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span dir=&quot;RTL&quot; lang=&quot;AR-KW&quot; style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.4pt;&quot; valign=&quot;top&quot; width=&quot;361&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Less than&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr&gt;   &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.35pt;&quot; valign=&quot;top&quot; width=&quot;360&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.4pt;&quot; valign=&quot;top&quot; width=&quot;361&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Greater   than&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr&gt;   &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.35pt;&quot; valign=&quot;top&quot; width=&quot;360&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;lt;=&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.4pt;&quot; valign=&quot;top&quot; width=&quot;361&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Less than   or equal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr&gt;   &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.35pt;&quot; valign=&quot;top&quot; width=&quot;360&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;gt;=&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.4pt;&quot; valign=&quot;top&quot; width=&quot;361&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Greater   than or equal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr&gt;   &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.35pt;&quot; valign=&quot;top&quot; width=&quot;360&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;lt;&amp;gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 270.4pt;&quot; valign=&quot;top&quot; width=&quot;361&quot;&gt;&lt;div align=&quot;center&quot; class=&quot;MsoNormal&quot; style=&quot;text-align: center;&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Not equal&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;By using these operators you can restrict rows returned by a query based on variety of condition.&lt;b&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Example 1&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Assume you want to retrieve a list of employees who earn monthly salary that is more than $2850.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;You will write the below &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Select ename,sal &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Where sal &amp;gt;2850; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #0070c0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;EXAMPLES FOR COMPARING EXPRETION&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;EXAMPL 1&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Select ename,sal &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Where sal =2850;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;EXAMPL2.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Select ename,sal &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;From emp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;Where sal &amp;gt;=2850;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2975&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #76923c; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2850&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;SCOTT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;KING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;FORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3000&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;EXAMPLES FOR COMPARING EXPRETION WITH DATES AND CHARACTER VALUES&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;1-DATES&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;SELECT ENAME,HIREDATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;WHERE HIREDATE&amp;lt;’ 01-JUL-81’;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HIREDATE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;---------- ---------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;SMITH&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 17-DEC-80&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 20-FEB-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 22-FEB-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;JONES&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 02-APR-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;BLAKE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 01-MAY-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;CLARK&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 09-JUN-81&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;2-CHRACTER&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;SELECT DEPTNO,LOC&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;FROM DEPT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;WHERE LOC &amp;lt;&amp;gt; ‘DALLAS’;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: red; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #005bc0; font-size: 12pt; line-height: 115%;&quot;&gt;DEPTNO LOC&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;-------- -------------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;10 NEW YORK&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;30 CHICAGO&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; font-family: inherit; font-size: 12pt; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;40 BOSTON&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 16px; line-height: 18px;&quot;&gt;&lt;b&gt;COMPARTION&amp;nbsp;&lt;/b&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;&lt;b&gt;AND NULL VALUES&amp;nbsp;&lt;/b&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white;&quot;&gt;&lt;b&gt;COMPARE SQL EDITIONS&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span lang=&quot;AR-KW&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: black; font-size: 9pt;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;When you use comparison operators in a where clause ,rowes that contain null result in null ,and are effectively not part of the result a value cannot be equal to ,greater than ,less than, or not equal to Null, because null is not a value.&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;  &lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;/span&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;For example&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;/span&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;Assume that you want a list of employees who earn a monthly salary that is greater than or equal to their annual commission. You select ename, Sal, and comm. from the EMP table and add a where clause restricting&amp;nbsp;results to those with a salary greater than or equal to commission.&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;u1:p&gt;&lt;/u1:p&gt;  &lt;/span&gt;&lt;div style=&quot;margin-bottom: .0001pt; margin: 0in;&quot;&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Check the below cod for more clarification&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;SELE&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;CT ENAME,SAL,COMM &lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;FROM EMP&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;WHERE SAL &amp;gt;= COMM;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; line-height: 115%;&quot;&gt;ENAME&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; SAL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; COMM&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; line-height: 115%;&quot;&gt;---------- ---------- ----------&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; line-height: 115%;&quot;&gt;ALLEN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1600&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 300&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; line-height: 115%;&quot;&gt;WARD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 500&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; line-height: 115%;&quot;&gt;TURNER&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #005bc0; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/6219026417833363709/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/comparing-excretion.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6219026417833363709'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6219026417833363709'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/comparing-excretion.html' title='Comparing Expression'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-6565477872554658420</id><published>2011-09-27T13:02:00.000-07:00</published><updated>2011-10-01T10:12:07.695-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Where"/><title type='text'>Where</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Where&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;You can restrict the rows returned from a query by using a where clause in SQL statement By inserting a WHERE clause into a SQL statement, you can specify a condition that must be met, and only the rows the condition are returned. This is also known as a selection.The where clause directly follows the FROM clause in SQL statement syntax. The WHERE clause consists of the WHERE keyword and condition or conditions&lt;/span&gt;&lt;b&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;.&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;font-size: 14pt;&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;Check the below example.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;font-size: 14pt;&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;Select empno,ename,deptno&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;From emp &lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;Where deptno=30;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; font-weight: bold;&quot;&gt;-&lt;/span&gt; Content of a condition&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;1- a column name like &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;depton &lt;/span&gt;in above example. That specifies the column that you want to restrict.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;2- Comparison operator like &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;= &lt;/span&gt;in above example .that specifies which rows are to be returned.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;3- Constant like &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;30 &lt;/span&gt;in above example .that specifies which rows are to be restricted.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;When you run the above query you will get the results for only department 30&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;line-height: 18px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-size: 12pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: red; line-height: 115%;&quot;&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-size: 14pt; line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/6565477872554658420/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/where.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6565477872554658420'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6565477872554658420'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/where.html' title='Where'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-6986996892077902183</id><published>2011-09-27T12:53:00.000-07:00</published><updated>2011-10-11T09:00:33.410-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Data type"/><title type='text'>Data type</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Data type&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 19pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white; font-family: Arial; font-size: 12px;&quot;&gt;SQL DATATYPES&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span lang=&quot;AR-KW&quot; style=&quot;background: white; color: black; font-family: Arial; font-size: 9.0pt; mso-bidi-language: AR-KW;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;NUMBER&lt;/span&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;: INDICATE THE COLUMN CONTAINS NUMBER.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;  &lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;EXAMPLE: &lt;span style=&quot;color: red;&quot;&gt;NUMBER (6, 2) &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;32155.01&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;The number in parentheses following this data type refers to the maximum of digits that the column may contain. A second number following the data type specifies the number of digits that the right of the decimal point in the number value.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;VARCHAR2&lt;/span&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;: INDICATE THE CLOUMN STORS A VARIABLE NUMBER OF CHARACTERS.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;Example: &lt;span style=&quot;color: red;&quot;&gt;VARCHAR2 (10) &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;‘ADAM’&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;THE NUMBER IN PARENTHESES FOLLOWING THIS DATATYPE SPECIFIES THE MAXIMUM OF CHARACTERS ALLOWED.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;DATE: &lt;/span&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;THE&lt;span style=&quot;color: red;&quot;&gt; &lt;/span&gt;DATE DATATYPE INDICATES THAT A COLUMN CONTAINS A DATE AND TIME THE VAIID DATE RANGE IS BETWEEN JANUARY 1.14712 B.C.AND DECEMBER 31.9999 A.D.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;EXAMPLE: &lt;span style=&quot;color: red;&quot;&gt;25-SEP-2011&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;CHAR:&lt;/span&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt; THE CHAR DATATYPE INDICATES THAT THE COLUMN STORES A FIXED-LENGTH CHARACTER VALUE . THE NUMBER IN PARENTHRSES FOLLOWING THIS DATATYPE SPECIFIES THE NUMBER OF CHARACTERS ALWAYS STORED.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;font-family: Arial; line-height: 115%;&quot;&gt;EXAMPLE : &lt;span style=&quot;color: red;&quot;&gt;CHAR(3)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;EMD&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;KNY&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: red; font-family: Arial; line-height: 115%;&quot;&gt;AD#&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/6986996892077902183/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/data-type.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6986996892077902183'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/6986996892077902183'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/data-type.html' title='Data type'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1031156110967948131.post-4569607358970924828</id><published>2011-09-26T09:59:00.000-07:00</published><updated>2011-10-11T09:02:36.963-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="TABLE STRUCTURE"/><title type='text'>DISPLAYING TABLE STRUCTURE</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;font-size: 16pt; line-height: 115%;&quot;&gt;DISPLAYING TABLE STRUCTURE.&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;div class=&quot;MsoNormal&quot; dir=&quot;RTL&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 12px;&quot;&gt;&lt;span dir=&quot;RTL&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Arial;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;apple-style-span&quot;&gt;&lt;span dir=&quot;LTR&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Arial;&quot;&gt;Structure of sql.&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;You can use the DESCRIBE command to see the column names, the data types ,And &amp;nbsp; &amp;nbsp;whether a column must contain data from a specific table.&lt;b style=&quot;font-size: 16pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgM_EfmWjXKbHn4TVe-HPt_cC_mqerE3ECJEf3LeeSZZ84dELxwp9YkxNchFp6iu4N5DUWv3XajeedE__eVjzNzxaRU9lw2c6ta2Gl0Jb2tQS2IlTfEmuSjWOzAtmv6F7AqXK-VER9gykQs/s1600/Describe.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;104&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgM_EfmWjXKbHn4TVe-HPt_cC_mqerE3ECJEf3LeeSZZ84dELxwp9YkxNchFp6iu4N5DUWv3XajeedE__eVjzNzxaRU9lw2c6ta2Gl0Jb2tQS2IlTfEmuSjWOzAtmv6F7AqXK-VER9gykQs/s320/Describe.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;Not you can write DESCRIBE command abbreviated. Like below and given same results.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEirv22xL9C0gxctaAp5vOBzYROdwoWkPD3DbfpfMC1YzJ81K9nA0PgGWaitTEXRCxKNzbQCEK9gPADhTS00qbkngCOwMnAj4MLM1J3jeFt9_gynW7V8G0VoWcIAFMPrgr9hAaR6Th3JwXqC/s1600/desc.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;104&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEirv22xL9C0gxctaAp5vOBzYROdwoWkPD3DbfpfMC1YzJ81K9nA0PgGWaitTEXRCxKNzbQCEK9gPADhTS00qbkngCOwMnAj4MLM1J3jeFt9_gynW7V8G0VoWcIAFMPrgr9hAaR6Th3JwXqC/s320/desc.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;line-height: 115%;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://oracle-sql-tutorials.blogspot.com/feeds/4569607358970924828/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/displaying-table-structure.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/4569607358970924828'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1031156110967948131/posts/default/4569607358970924828'/><link rel='alternate' type='text/html' href='http://oracle-sql-tutorials.blogspot.com/2011/09/displaying-table-structure.html' title='DISPLAYING TABLE STRUCTURE'/><author><name>Emad</name><uri>http://www.blogger.com/profile/05284195510335470235</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgM_EfmWjXKbHn4TVe-HPt_cC_mqerE3ECJEf3LeeSZZ84dELxwp9YkxNchFp6iu4N5DUWv3XajeedE__eVjzNzxaRU9lw2c6ta2Gl0Jb2tQS2IlTfEmuSjWOzAtmv6F7AqXK-VER9gykQs/s72-c/Describe.jpg" height="72" width="72"/><thr:total>0</thr:total></entry></feed>