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

<channel>
	<title>difference between procedure and function in mssql - Wikitechy</title>
	<atom:link href="https://www.wikitechy.com/interview-questions/tag/difference-between-procedure-and-function-in-mssql/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.wikitechy.com/interview-questions/tag/difference-between-procedure-and-function-in-mssql/</link>
	<description>Interview Questions</description>
	<lastBuildDate>Wed, 08 Sep 2021 11:51:30 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://www.wikitechy.com/interview-questions/wp-content/uploads/2025/10/cropped-wikitechy-icon-32x32.png</url>
	<title>difference between procedure and function in mssql - Wikitechy</title>
	<link>https://www.wikitechy.com/interview-questions/tag/difference-between-procedure-and-function-in-mssql/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Difference between Procedure and Function ?</title>
		<link>https://www.wikitechy.com/interview-questions/oracle/difference-between-procedure-and-function/</link>
					<comments>https://www.wikitechy.com/interview-questions/oracle/difference-between-procedure-and-function/#respond</comments>
		
		<dc:creator><![CDATA[Editor]]></dc:creator>
		<pubDate>Tue, 20 Jul 2021 09:28:09 +0000</pubDate>
				<category><![CDATA[Oracle]]></category>
		<category><![CDATA[Accenture interview questions and answers]]></category>
		<category><![CDATA[Allstate Solutions Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[Amdocs interview questions and answers]]></category>
		<category><![CDATA[Atos interview questions and answers]]></category>
		<category><![CDATA[Capgemini interview questions and answers]]></category>
		<category><![CDATA[CASTING NETWORKS INDIA PVT LIMITED interview questions and answers]]></category>
		<category><![CDATA[CGI Group Inc interview questions and answers]]></category>
		<category><![CDATA[Collabera Technologies interview questions and answers]]></category>
		<category><![CDATA[Conduent interview questions and answers]]></category>
		<category><![CDATA[Dell International Services India Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[difference between function and cursor]]></category>
		<category><![CDATA[difference between function and procedure]]></category>
		<category><![CDATA[difference between function and procedure in sql]]></category>
		<category><![CDATA[difference between function and procedure in sql server]]></category>
		<category><![CDATA[difference between function and procedure in vb]]></category>
		<category><![CDATA[difference between function and procedure in vhdl]]></category>
		<category><![CDATA[difference between procedure and function and package in oracle]]></category>
		<category><![CDATA[difference between procedure and function in c]]></category>
		<category><![CDATA[difference between procedure and function in mssql]]></category>
		<category><![CDATA[difference between procedure and function in mysql]]></category>
		<category><![CDATA[difference between procedure and function in oracle]]></category>
		<category><![CDATA[difference between procedure and function in oracle 11g]]></category>
		<category><![CDATA[difference between procedure and function in pl sql]]></category>
		<category><![CDATA[difference between procedure and function in tabular form]]></category>
		<category><![CDATA[difference between stored procedure and function]]></category>
		<category><![CDATA[difference between stored procedure and function in mysql]]></category>
		<category><![CDATA[difference between stored procedure and function in oracle]]></category>
		<category><![CDATA[difference between stored procedure and function in sql]]></category>
		<category><![CDATA[difference between stored procedure and function in sql server]]></category>
		<category><![CDATA[FIS Global Business Solutions India Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[functions and procedures in sql]]></category>
		<category><![CDATA[Genpact interview questions and answers]]></category>
		<category><![CDATA[how to call a procedure in oracle]]></category>
		<category><![CDATA[how to create a procedure inside a package in oraclepl sql procedures and functions with examplere]]></category>
		<category><![CDATA[IBM interview questions and answers]]></category>
		<category><![CDATA[Indecomm Global Services interview questions and answers]]></category>
		<category><![CDATA[Infogain interview questions and answers]]></category>
		<category><![CDATA[L&T Infotech interview questions and answers]]></category>
		<category><![CDATA[Mphasis interview questions and answers]]></category>
		<category><![CDATA[Oracle Corporation interview questions and answers]]></category>
		<category><![CDATA[polaris financial technology interview questions and answers]]></category>
		<category><![CDATA[procedures and functions in oracle with examples]]></category>
		<category><![CDATA[Prokarma Softech Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[SAP Labs India Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[similarities between function and procedurestored procedure vs function in sql server performance]]></category>
		<category><![CDATA[stored procedure and function difference]]></category>
		<category><![CDATA[subroutines functions and procedures]]></category>
		<category><![CDATA[Synechron Technologies Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[Tata Consultancy Service interview questions and answers]]></category>
		<category><![CDATA[Tech Mahindra interview questions and answers]]></category>
		<category><![CDATA[turn in oracle stored procedure]]></category>
		<category><![CDATA[UnitedHealth Group interview questions and answers]]></category>
		<category><![CDATA[Virtusa Consulting Services Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[Wells Fargo interview questions and answers]]></category>
		<category><![CDATA[what is difference between stored procedure and function]]></category>
		<category><![CDATA[what is stored procedure in oracle]]></category>
		<category><![CDATA[what is the difference between function and procedure]]></category>
		<category><![CDATA[why we use package in oracle]]></category>
		<category><![CDATA[Wipro Infotech interview questions and answers]]></category>
		<category><![CDATA[Xoriant Solutions Pvt Ltd interview questions and answers]]></category>
		<category><![CDATA[Zensar Technologies interview questions and answers]]></category>
		<guid isPermaLink="false">https://www.wikitechy.com/interview-questions/?p=1135</guid>

					<description><![CDATA[Answer : A procedure is a named PL/SQL block...]]></description>
										<content:encoded><![CDATA[<div class="TextHeading">
<div class="hddn">
<h2 id="difference-between-procedure-and-function" class="color-pink">Difference between Procedure and Function ?</h2>
</div>
</div>
<div class="TextHeading">
<div class="hddn">
<h2 id="procedure" class="color-purple">Procedure</h2>
</div>
</div>
<div class="Content">
<div class="hddn">
<ul>
<li>A procedure is a named PL/SQL block which performs one or more specific task.This is similar to a procedure in other programming languages.</li>
<li>A procedure has a header and a body.</li>
<li>The <b>header</b> consists of the name of the procedure and the parameters or variables passed to the procedure.</li>
<li>The <b>body</b> consists declaration section, execution section and exception section similar to a general PL/SQL Block. A procedure is similar to an anonymous PL/SQL Block but it is named for repeated usage.</li>
</ul>
</div>
</div>
<div class="TextHeading">
<div class="hddn">
<h2 id="we-can-pass-parameters-to-procedures-in-three-ways" class="color-purple">We can pass parameters to procedures in three ways</h2>
</div>
</div>
<div class="table-responsive">
<table class="table-bordered table-striped table table-responsive">
<tbody>
<tr>
<th>Parameters</th>
<th>Description</th>
</tr>
<tr>
<td>IN type</td>
<td>These types of parameters are used to send values to stored procedures</td>
</tr>
<tr>
<td>OUT type</td>
<td>These types of parameters are used to get values from stored procedures. This is similar to a return type in functions.</td>
</tr>
<tr>
<td>IN OUT type</td>
<td>These types of parameters are used to send values and get values from stored procedures.</td>
</tr>
</tbody>
</table>
</div>
<div class="TextHeading">
<div class="hddn">
<h2 id="syntax" class="color-purple">Syntax</h2>
<div class="code-embed-wrapper"> <div class="code-embed-infos"> </div> <pre class="language-markdown code-embed-pre line-numbers"  data-start="1" data-line-offset="0"><code class="language-markdown code-embed-code">CREATE [OR REPLACE] PROCEDURE procedure_name (&lt;Argument&gt; {IN, OUT, IN OUT}    &lt;Datatype&gt;,…)  <br/>IS <br/>  Declaration section&lt;variable, constant&gt; ; <br/>BEGIN <br/>  Execution section <br/>EXCEPTION <br/>  Exception section  <br/>END</code></pre> </div>
</div>
</div>
<div class="TextHeading">
<div class="hddn">
<h2 id="functions" class="color-purple">Functions</h2>
</div>
</div>
<div class="Content">
<div class="hddn">
<ul>
<li>A function is a named PL/SQL Block which is similar to a procedure.</li>
<li>The major difference between a procedure and a function is, a function must always return a value, but a procedure may or may not return a value.</li>
</ul>
</div>
</div>
<div class="TextHeading">
<div class="hddn">
<h2 id="syntax-2" class="color-purple">Syntax</h2>
<div class="code-embed-wrapper"> <div class="code-embed-infos"> </div> <pre class="language-markdown code-embed-pre line-numbers"  data-start="1" data-line-offset="0"><code class="language-markdown code-embed-code">CREATE [OR REPLACE] FUNCTION function_name [parameters]  <br/> RETURN return_datatype;  {IS, AS} <br/> Declaration_section &lt;variable,constant&gt; ;<br/> BEGIN   <br/>    Execution_section <br/>    Return return_variable;   <br/> EXCEPTION <br/>   exception section   <br/>    Return return_variable;  <br/> END;</code></pre> </div>
</div>
</div>
<div class="TextHeading">
<div class="hddn">
<h2 id="procedure-vs-function" class="color-purple">Procedure vs function</h2>
</div>
</div>
<div class="table-responsive">
<table class="table-bordered table-striped table table-responsive">
<tbody>
<tr>
<th>Procedure</th>
<th>Function</th>
</tr>
<tr>
<td>Used mainly to a execute certain process.</td>
<td>Used mainly to perform some calculation.</td>
</tr>
<tr>
<td>Cannot call in SELECT statement.</td>
<td>A Function that contains no DML statements can be called in SELECT statement.</td>
</tr>
<tr>
<td>Use OUT parameter to return the value.</td>
<td>Use RETURN to return the value.</td>
</tr>
<tr>
<td>It is not mandatory to return the value.</td>
<td>It is mandatory to return the value.</td>
</tr>
<tr>
<td>RETURN will simply exit the control from subprogram.</td>
<td>RETURN will exit the control from subprogram and also returns the value.</td>
</tr>
<tr>
<td>Return datatype will not be specified at the time of creation.</td>
<td>Return datatype is mandatory at the time of creation.</td>
</tr>
</tbody>
</table>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://www.wikitechy.com/interview-questions/oracle/difference-between-procedure-and-function/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
