<?xml version="1.0" encoding="UTF-8" standalone="no"?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:blogger="http://schemas.google.com/blogger/2008" xmlns:gd="http://schemas.google.com/g/2005" xmlns:georss="http://www.georss.org/georss" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/" xmlns:thr="http://purl.org/syndication/thread/1.0" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-6921611210899688855</atom:id><lastBuildDate>Thu, 03 Oct 2024 07:54:05 +0000</lastBuildDate><category>Architecture</category><category>.Net Articles</category><category>Biztalk</category><category>DBMS</category><category>Sharepoint</category><title>Software Engineering</title><description></description><link>http://etechmentors.blogspot.com/</link><managingEditor>noreply@blogger.com (Adul Malik)</managingEditor><generator>Blogger</generator><openSearch:totalResults>18</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><language>en-us</language><itunes:explicit>no</itunes:explicit><itunes:keywords>C,JavaScript,Ajax,net,Design,Pattern,Architecture,Designing,SQL,Server,Business,Intelligence,Sharepoint</itunes:keywords><itunes:summary>C# , JavaScript , Ajax, .net, Design Pattern , Architecture Designing, SQL Server, Business Intelligence, Sharepoint</itunes:summary><itunes:subtitle>Software Engineering</itunes:subtitle><itunes:category text="Technology"><itunes:category text="Gadgets"/></itunes:category><itunes:owner><itunes:email>etechmentor@gmail.com</itunes:email></itunes:owner><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-7165600790376238308</guid><pubDate>Thu, 01 Jul 2010 12:38:00 +0000</pubDate><atom:updated>2010-07-01T05:38:50.176-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">.Net Articles</category><title>The request failed with HTTP status 417: Expectation failed.</title><description>&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&lt;span class="Apple-style-span" style="color: black;"&gt;When using WebServices and calling some Web Methods, you may come across to this exception:&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class="quoted" style="background-attachment: initial; background-clip: initial; background-color: initial; background-image: url(http://images.experts-exchange.com/00165/xp/images/largeQuote.png); background-origin: initial; background-position: 0% 0%; background-repeat: no-repeat no-repeat; font-size: 12px; margin-bottom: 0px; margin-left: 60px; margin-right: 60px; margin-top: 5px; min-height: 44px; padding-bottom: 0px; padding-left: 10px; padding-right: 0px; padding-top: 6px;"&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&lt;b&gt;"The request failed with HTTP status 417: Expectation failed."&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;b&gt;Solution:&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;b&gt;&lt;br /&gt;
&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;It is easy, here are two alternative ways:&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;1) We need to have this line of code before making any web requests.&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class="codeSnippet" style="background-color: white; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-top-color: silver; border-top-style: solid; border-top-width: 1px; clear: both; color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 17px; max-height: 500px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;table style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;tbody style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;
&lt;tr style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;td class="lineNumbers" style="border-right-color: silver; border-right-style: solid; border-right-width: 1px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 2px; padding-right: 2px; padding-top: 0px; text-align: right; vertical-align: top;"&gt;&lt;pre style="font-size: 12px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;1:
&lt;/pre&gt;&lt;/td&gt;&lt;td class="codeBody" style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 2px; padding-right: 2px; padding-top: 0px; vertical-align: top;"&gt;&lt;pre class="notpretty" id="codeSnippet0" style="font-size: 12px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;System.Net.ServicePointManager.Expect100Continue = false;
&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="clear" style="clear: both; color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px; height: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;2) Add these lines to the application's configuration file (between &amp;lt;configuration&amp;gt; and &amp;lt;/configuration&amp;gt;):&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;div class="codeSnippet" style="background-color: white; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-top-color: silver; border-top-style: solid; border-top-width: 1px; clear: both; color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 17px; max-height: 500px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;table style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;tbody style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;
&lt;tr style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;td class="lineNumbers" style="border-right-color: silver; border-right-style: solid; border-right-width: 1px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 2px; padding-right: 2px; padding-top: 0px; text-align: right; vertical-align: top;"&gt;&lt;pre style="font-size: 12px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;1:
2:
3:
4:
5:
&lt;/pre&gt;&lt;/td&gt;&lt;td class="codeBody" style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 2px; padding-right: 2px; padding-top: 0px; vertical-align: top;"&gt;&lt;pre class="notpretty" id="codeSnippet0" style="font-size: 12px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&amp;lt;system.net&amp;gt;
 &amp;lt;settings&amp;gt;
  &amp;lt;servicePointManager expect100Continue="false" /&amp;gt;
 &amp;lt;/settings&amp;gt;
&amp;lt;/system.net&amp;gt;
&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="clear" style="clear: both; color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px; height: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;While this workaround is nice, I think a better long term solution is to upgrade/replace the proxy server to handle 100-continue calls.&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: arial, helvetica, sans-serif; font-size: 12px;"&gt;So far in this short tip we've learned what is Expect 100, how it is caused and how to workaround this expectation.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/07/request-failed-with-http-status-417.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-2391404890731017485</guid><pubDate>Thu, 01 Jul 2010 11:22:00 +0000</pubDate><atom:updated>2010-07-01T04:22:52.158-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">.Net Articles</category><title>ASP.NET AJAX - Update Panel Timeout</title><description>&lt;div style="font-family: 'Lucia Grande', Verdana, 'Times New Roman', Times, serif; font-size: 13px;"&gt;When using the&amp;nbsp;&lt;span style="color: #993300; font-family: 'courier new';"&gt;asp:UpdatePanel&lt;/span&gt;&amp;nbsp;server control for asyncronous communication with the web server the default timeout is 90 seconds. For some processes this may not be long enough.&lt;/div&gt;&lt;div style="font-family: 'Lucia Grande', Verdana, 'Times New Roman', Times, serif; font-size: 13px;"&gt;For example, I am currently working on a reporting application and at the moment I have to query a table with over 36 million records. Some queries take longer than 90 seconds. But unfortunately I had trouble finding out how to extend this.&lt;/div&gt;&lt;div style="font-family: 'Lucia Grande', Verdana, 'Times New Roman', Times, serif; font-size: 13px;"&gt;It turns out that this is a page-level setting. The&amp;nbsp;&lt;span style="color: #993300; font-family: 'courier new';"&gt;asp:ScriptManager&lt;/span&gt;&amp;nbsp;server control has a property named&lt;span style="color: #993300; font-family: 'courier new';"&gt;AsyncPostBackTimeout&lt;/span&gt;. Set this value to the number of seconds you need to resonably run the process in question and you'll be fine.&lt;/div&gt;&lt;div style="font-family: 'Lucia Grande', Verdana, 'Times New Roman', Times, serif; font-size: 13px;"&gt;&lt;span style="color: #993300; font-family: 'courier new';"&gt;&amp;lt;asp:scriptmanager id="scriptManager1" runat="server" enablepartialrendering="true" asyncpostbacktimeout="1000"&amp;gt;&amp;lt;/asp:ScriptManager&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/07/aspnet-ajax-update-panel-timeout.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-3162409759065571368</guid><pubDate>Fri, 09 Apr 2010 12:40:00 +0000</pubDate><atom:updated>2010-04-09T05:40:09.386-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Architecture</category><title>SOAP vs REST Web Services</title><description>&lt;span class="Apple-style-span" style="font-family: Arial; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 13px;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class="Apple-style-span" style="font-family: Arial; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 13px;"&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;For the past two years, the hype surrounding the Simple Object Access Protocol (&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: blue;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;SOAP&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;) has barely waned, although its opponents have gradually risen in number. While some critics are simply tired of hearing about Web services, a small handful of Internet architects have come up with a surprisingly good argument for pushing SOAP aside: there's a better method for building Web services in the form of &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Representational State Transfer&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; (&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: blue;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;REST&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;).&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;REST is more an old philosophy than a new technology. Whereas SOAP looks to jump-start the next phase of Internet development with a host of new specifications, the &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;REST philosophy espouses that the existing principles and protocols of the Web are enough to create robust Web services&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;. This means that developers who understand HTTP and XML can start building Web services right away, without needing any toolkits beyond what they normally use for Internet application development.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Interface Flexibility&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt; &lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;The key to the REST methodology is to write Web services using an interface that is already well known and widely used&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;: the URI. For example, exposing a stock quote service, in which a user enters a stock quote symbol to return a real-time price, could be as simple as making a script accessible on a Web server via the following URI: http://www.somebrokerage.com/quote&lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;?symbol=QQQ&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Any client or server application with HTTP support could easily call that service with an &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;HTTP GET command&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;. Depending on how the service provider wrote the script, the resulting HTTP response might be as simple as some standard headers and a text string containing the current price for the given ticker symbol. Or, it might be an XML document.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;This interface method has significant benefits over SOAP-based services. Any developer can figure out how to create and modify a &lt;/span&gt;&lt;/span&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;URI &lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span class="MsoCommentReference"&gt;&lt;a class="msocomanchor" href="http://www.blogger.com/post-create.g?blogID=6921611210899688855#_msocom_1" id="_anchor_1" language="JavaScript" name="_msoanchor_1"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;[a1]&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;to access different Web resources. SOAP, on the other hand, requires specific knowledge of a new XML specification, and most developers will need a SOAP toolkit to form requests and parse the results.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Lighter on Bandwidth&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
Another benefit of the RESTful interface is that &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;requests&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; and &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;responses&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; can be short. &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;SOAP requires an XML wrapper around every request and response&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;. Once namespaces and typing are declared, a four- or five-digit stock quote in a SOAP response could require more than 10 times as many bytes as would the same response in REST.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;SOAP proponents argue that strong typing is a necessary feature for distributed applications. In practice, though, both the requesting application and the service know the &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;data types&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; ahead of time; thus, transferring that information in the requests and responses is gratuitous.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;How does one know the data types—and their locations in the response—ahead of time? Like SOAP, REST still needs a corresponding document that outlines input parameters and output data. The good part is that &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;REST is flexible enough that developers could write WSDL files for their services&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; if such a formal declaration was necessary. Otherwise, the declaration could be as simple as a human-readable Web page that says, "Give this service an input of some stock ticker symbol, in the format q=symbol, and it will return the current price of one share of stock as a text string."&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Security Safeguards&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
Probably the most interesting aspect of the &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;REST vs. SOAP&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; debate is the security angle. Although the SOAP camp insists that sending &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;remote procedure calls through standard HTTP&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; ports is a good way to ensure Web services support across organizational boundaries, REST followers argue that the practice is a major design flaw that compromises network safety. REST calls also go over HTTP or HTTPS, but with REST the administrator (or firewall) can discern the intent of each message by analyzing the HTTP command used in the request. For example, &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;a GET request can always be considered safe because it can't, by definition, modify any data. It can only query data&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;A typical SOAP request, on the other hand, will use POST to communicate with a given service. And without looking into the &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;SOAP envelope&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;—a task that is both resource-consuming and not built into most firewalls—there's no way to know whether that request simply wants to query data or delete entire tables from the database.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;As for authentication and authorization, SOAP places the burden in the hands of the application developer. The REST methodology instead takes into account the fact that Web servers already have support for these tasks. Through the use of &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;industry-standard certificates&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; and a &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;common identity management system&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;, such as an &lt;/span&gt;&lt;/span&gt;&lt;span style="background-attachment: initial; background-clip: initial; background-color: yellow; background-image: initial; background-origin: initial;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;LDAP server&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;, developers can make the network layer do all the heavy lifting.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;This is not only helpful to developers, but it eases the burden on administrators, who can use something as simple as &lt;/span&gt;&lt;/span&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;ACL&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span class="MsoCommentReference"&gt;&lt;a class="msocomanchor" href="http://www.blogger.com/post-create.g?blogID=6921611210899688855#_msocom_2" id="_anchor_2" language="JavaScript" name="_msoanchor_2"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;[a2]&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt; files to manage their Web services the same way they would any other URI.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Not For Everything&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
To be fair, REST isn't the best solution for every Web service. &lt;/span&gt;&lt;/span&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Data that needs to be secure should not be sent as parameters in URIs&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span class="MsoCommentReference"&gt;&lt;a class="msocomanchor" href="http://www.blogger.com/post-create.g?blogID=6921611210899688855#_msocom_3" id="_anchor_3" language="JavaScript" name="_msoanchor_3"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;[a3]&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;. And large amounts of data, like that in detailed purchase orders, can quickly become cumbersome or even out of bounds within a URI. In these cases, SOAP is indeed a solid solution. But it's important to try REST first and resort to SOAP only when necessary. This helps keep application development simple and accessible.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Fortunately, the REST philosophy is catching on with developers of Web services. The latest version of the SOAP specification now allows certain types services to be exposed through URIs (although the response is still a SOAP message). Similarly, users of Microsoft .NET platform can publish services so that they use GET requests. All this signifies a shift in thinking about how best to interface Web services.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Developers need to understand that sending and receiving a SOAP message isn't always the best way for applications to communicate. Sometimes a simple REST interface and a plain text response does the trick—and saves time and resources in the process.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="mso-element: comment-list;"&gt;&lt;hr align="left" class="msocomoff" size="1" width="33%" /&gt;&lt;div&gt;&lt;div class="msocomtxt" id="_com_1" language="JavaScript"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" name="_msocom_1"&gt;&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class="MsoCommentText"&gt;&lt;span class="MsoCommentReference"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;a class="msocomoff" href="http://www.blogger.com/post-create.g?blogID=6921611210899688855#_msoanchor_1"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;[a1]&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Universal Resouce Identifier&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;div class="msocomtxt" id="_com_2" language="JavaScript"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" name="_msocom_2"&gt;&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class="MsoCommentText"&gt;&lt;span class="MsoCommentReference"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;a class="msocomoff" href="http://www.blogger.com/post-create.g?blogID=6921611210899688855#_msoanchor_2"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;[a2]&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Active Control List&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="mso-element: comment;"&gt;&lt;div class="msocomtxt" id="_com_3" language="JavaScript"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" name="_msocom_3"&gt;&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;  &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div class="MsoCommentText"&gt;&lt;span class="MsoCommentReference"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;a class="msocomoff" href="http://www.blogger.com/post-create.g?blogID=6921611210899688855#_msoanchor_3"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;[a3]&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Very Important &lt;/span&gt;&lt;/span&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: small;"&gt;Notes&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/04/soap-vs-rest-web-services.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-8009441071959794792</guid><pubDate>Thu, 25 Mar 2010 10:35:00 +0000</pubDate><atom:updated>2010-03-25T03:35:52.697-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">.Net Articles</category><title>C# MIDI</title><description>&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibV3Gsub-WicN31S4JaG-kzkjTOLUX_KO9R9BWbC1uq0rf5g3kwnuMBN85GVzrkx-LxgbveK2MlqQ_W8qCZjZ3VQ6LPX-ohD4DYbcMIeUJWodTM_BHyL13M5EiXrMxyOtG_jsik5e0AU46/s1600/SequencerDemo.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibV3Gsub-WicN31S4JaG-kzkjTOLUX_KO9R9BWbC1uq0rf5g3kwnuMBN85GVzrkx-LxgbveK2MlqQ_W8qCZjZ3VQ6LPX-ohD4DYbcMIeUJWodTM_BHyL13M5EiXrMxyOtG_jsik5e0AU46/s320/SequencerDemo.png" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;h2&gt;&amp;nbsp;&lt;/h2&gt;&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Intro"&gt;Introduction&lt;/a&gt;&lt;/h2&gt;This is the fifth version of my .NET MIDI toolkit. I had thought that the previous          version was the final one, but I have made many changes that have warranted a          new version. This version takes a more traditional C#/.NET approach to          flow-based programming, which I'll describe below. I wasn't comfortable with          version four's implementation along these lines, so I took a step back and made          changes that keep the flow-based approach while remaining within C#/.NET          accepted idioms. I'm hoping that this will make the toolkit easier to use and          understand.     &lt;br /&gt;
The toolkit has seen many revisions over the past two to three years. Each revision          has been an almost total rewrite of the previous one. When writing software, it          is usually a bad idea to make updates that break software using previous          versions. However, my goal in creating this toolkit has been to provide the          best design possible. As I have grown as a programmer, I have improved my          skills and understanding of software design. This has led me to revise the          earlier designs of the toolkit without regard to how these revisions will break          code. Not exactly the attitude one wants to adopt in a professional setting,          but since the toolkit is free and since I have used it as a learning experience          to improve my craft, my priorities are different.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Flow"&gt;Flow-based programming&lt;/a&gt;&lt;/h2&gt;Before I get into the specifics of the toolkit, I would like to talk about its          architecture. With each version of the toolkit, I have struggled with how to          structure the flow of messages through the system. I wanted an approach that          would be versatile and allow customization. It would be nice, I thought, if          users could plug their own classes into the flow of MIDI messages to do          whatever they want. For example, say you wanted to write a harmonizer, a class          capable of transposing notes in a specified key to create harmony parts          automatically. It should be easy to simply plug the harmonizer into the toolkit          without affecting other classes. In other words, the toolkit should be          customizable and configurable.&lt;br /&gt;
Investigating this problem led me to J. Paul Morrison's excellent &lt;a href="http://www.jpaulmorrison.com/fbp/" target="_blank"&gt;             website&lt;/a&gt; on flow-based programming. He has written a book on the          subject, which can be found on his website as well as at &lt;a href="http://www.amazon.com/gp/product/0442017715/102-7490421-2133727?n=283155" target="_blank"&gt;Amazon&lt;/a&gt;.&lt;br /&gt;
The idea is simple and will probably seem familiar to most: Data flows through a          network of components. Each component can do something interesting with the          data before passing it along to the next component. In design pattern terms,          this approach is most like the Pipe and Filter pattern and is also similar to          the Chain of Responsibility pattern. Please check out J. Paul Morrison's          excellent book for more information.&lt;br /&gt;
(Just to be clear: when I say "component," I'm not necessarily talking about classes          that implement the &lt;code&gt;IComponent&lt;/code&gt; interface. I'm speaking in more          general terms. A component is simply an object in a chain of objects designed          to process the flow of messages.)&lt;br /&gt;
Below is a very basic network of components designed to handle the flow of MIDI          channel messages:&lt;br /&gt;
&lt;img alt="Screenshot - MessageFlow.PNG" height="49" src="http://www.codeproject.com/KB/audio-video/MIDIToolkit/MessageFlow.PNG" width="467" /&gt;&lt;br /&gt;
The flow of messages begins with the input device. An input device receives MIDI          messages from an external source. Next, the messages flow through a user          component. This component might want to do something like change the MIDI          channel, transpose note messages, or change the messages in some way. Then the          messages pass through the channel stopper. This component simply keeps track of          all currently sounding notes. When the message flow stops, the channel stopper          can turn off all sounding notes so that none of them hang. Finally, the          messages reach the output device. Here they are sent to an external MIDI          device.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h3&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="ImplementingFlow"&gt;Implementing flow-based programming in C#&lt;/a&gt;&lt;/h3&gt;Well, this is something I really struggled with. You can read a bit about the          different ways I tried to achieve this by reading my blog. I found myself going round in circles on this. In version four of          the toolkit, I settled on the idea of using a source/sink abstraction. I created          an interface representing "Sources." A source represents a source of MIDI          messages. "Sinks" were represented by delegates that could be connected to          sources; a sink is simply a method capable of receiving a MIDI message. This          worked well but it was a little confusing because the implementation looked a          little "funny." That is to say, a C# programmer looking at the code for the          first time might be confused as to what is going on.&lt;br /&gt;
I decided to do away with the sink/source infrastructure and use something more          idiomatic. Sources of MIDI messages raise events when they have messages to          send. Instead of implementing an interface and having &lt;code&gt;Connect&lt;/code&gt; and &lt;code&gt;             Disconnect&lt;/code&gt; methods for hooking to sinks, they would simply have          events. There are two advantages here: First, sources no longer have to          implement an &lt;code&gt;ISource&lt;/code&gt; interface, and second, .NET events are          something very familiar to us. So sources of MIDI messages now look like your          everyday class that just happens to have one or more events.&lt;br /&gt;
How about sinks, those objects that can &lt;i&gt;receive&lt;/i&gt; MIDI messages? A sink can be          anything. It's just an object that has a method that can receive a MIDI          message. In version four, I had a &lt;code&gt;Sink&lt;/code&gt; delegate for representing          methods of objects capable of receiving MIDI messages. These delegates were          used to connect with sources. This approach of using delegates to "connect"          sources and sinks is still used in the toolkit but not as before. Instead,          delegates are used as adaptors that connect to the events raised in sources and          adapts the events so that objects that need to receive the messages can do so          without any knowledge of the source.     &lt;br /&gt;
Let's look at an example. Say that we're using an &lt;code&gt;InputDevice&lt;/code&gt; to          receive MIDI messages from a MIDI device, such as your soundcard. The &lt;code&gt;InputDevice&lt;/code&gt;         raises a &lt;code&gt;ChannelMessageReceived&lt;/code&gt; event each time it receives a          channel message. Suppose that we want to keep track of any note-on channel          messages so that when we decide to stop receiving messages, we can turn off any          currently sounding notes to keep them from "hanging." The &lt;code&gt;ChannelStopper&lt;/code&gt;         class is just for this purpose. However, the &lt;code&gt;ChannelStopper&lt;/code&gt; has no          knowledge of the &lt;code&gt;InputDevice&lt;/code&gt; class. We need a way to hook them up          so that messages generated by the &lt;code&gt;InputDevice&lt;/code&gt; can be passed along          to the &lt;code&gt;ChannelStopper&lt;/code&gt;. Here is how we can do this with an          anonymous method:     &lt;br /&gt;
&lt;div class="small-text" id="premain0" style="cursor: pointer; width: 100%;"&gt;&lt;span id="precollapse0" preid="0" style="margin-bottom: 0pt;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;pre id="pre0" lang="cs" style="margin-top: 0pt;"&gt;InputDevice inDevice = &lt;span class="code-keyword"&gt;new&lt;/span&gt; InputDevice(&lt;span class="code-digit"&gt;0&lt;/span&gt;);
ChannelStopper stopper = &lt;span class="code-keyword"&gt;new&lt;/span&gt; ChannelStopper();

inDevice.ChannelMessageReceived += &lt;span class="code-keyword"&gt;delegate&lt;/span&gt;(&lt;span class="code-keyword"&gt;object&lt;/span&gt; sender, ChannelMessageEventArgs e)
{
    stopper.Process(e.Message);
};

inDevice.StartRecording();

&lt;span class="code-comment"&gt;//&lt;/span&gt;&lt;span class="code-comment"&gt; ...&lt;/span&gt;&lt;/pre&gt;In this example, an anonymous method adapts events raised by the &lt;code&gt;InputDevice&lt;/code&gt;         so that they can be processed by a &lt;code&gt;ChannelStopper&lt;/code&gt;. The &lt;code&gt;InputDevice&lt;/code&gt;         is the source of channel messages and the &lt;code&gt;ChannelStopper&lt;/code&gt; is a sink          capable of receiving and processing channel messages. The nice thing about this          approach is that no explicit source/sink infrastructure is needed. Neither          class knows anything about being a source or sink. The flow of messages is          orchestrated by an external agent, in this case, an anonymous method.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Messages"&gt;MIDI messages&lt;/a&gt;&lt;/h2&gt;There are several categories of MIDI messages: Channel, System Exclusive, Meta, etc.          In designing a MIDI toolkit, the challenge is to decide how to represent these          messages. One approach is to create two or three general MIDI classes and have          specific types of MIDI messages represented through the properties of those          classes. The Java MIDI API takes this route. Another approach is to create a          large collection of finely grained classes to represent all of the different          types of MIDI messages. For example, there are many types of Channel messages          such as the Note-on, Note-off, Program change, and Pitch Bend messages. The          fine grained approach would create a class for each of those message types. My          approach was to take a middle ground. I created classes for the general          categories of MIDI messages but left the specific types of messages as          properties within those classes. This kept the class hierarchy lightweight and          manageable while providing enough specialization to make working with MIDI          messages easy.&lt;br /&gt;
Here is the hierarchy of MIDI message classes in the MIDI toolkit:&lt;br /&gt;
&lt;ul&gt;&lt;li&gt;             &lt;code&gt;IMidiMessage&lt;/code&gt;             &lt;br /&gt;
&lt;ul&gt;&lt;li&gt;                     &lt;code&gt;ShortMessage&lt;/code&gt;                     &lt;br /&gt;
&lt;ul&gt;&lt;li&gt;                             &lt;code&gt;ChannelMessage&lt;/code&gt;                         &lt;/li&gt;
&lt;li&gt;                             &lt;code&gt;SysCommonMessage&lt;/code&gt;                         &lt;/li&gt;
&lt;li&gt;                             &lt;code&gt;SysRealtimeMessage&lt;/code&gt;                         &lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;li&gt;                     &lt;code&gt;SysExMessage&lt;/code&gt;                 &lt;/li&gt;
&lt;li&gt;                     &lt;code&gt;MetaMessage&lt;/code&gt;                 &lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;/ul&gt;Specific types of messages are represented through properties. For example, the &lt;code&gt;ChannelMessage&lt;/code&gt;         class has a &lt;code&gt;Command&lt;/code&gt; property that can be set to represent the          various types of Channel messages.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h3&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Builders"&gt;Message builders&lt;/a&gt;&lt;/h3&gt;All message classes are immutable. This makes sharing messages throughout an          application safe. To create messages, you pass the desired property values to          their constructor. Additionally, the toolkit provides a set of builder classes          for making message creation more convenient.&lt;br /&gt;
The toolkit provides the following message builders:&lt;br /&gt;
&lt;ul&gt;&lt;li&gt;             &lt;code&gt;ChannelMessageBuilder&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;SysCommonMessageBuilder&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;KeySignatureBuilder&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;MetaTextBuilder&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;SongPositionPointerBuilder&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;TempoChangeBuilder&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;TimeSignatureBuilder&lt;/code&gt;         &lt;/li&gt;
&lt;/ul&gt;The &lt;code&gt;ChannelMessageBuilder&lt;/code&gt; and the &lt;code&gt;SysCommonBuilder&lt;/code&gt; also          use the Flyweight design pattern. When a new message is built, it is stored in          a cache. When another message is needed that has the exact same properties as a          message that has already been built, the previous message is retrieved rather          than creating a new one. When you consider that a typical MIDI sequence is made          up of thousands of messages, many of them identical, it is easy to see how the          Flyweight pattern is applicable.&lt;br /&gt;
Here is an example of creating a &lt;code&gt;ChannelMessage&lt;/code&gt; object representing a          note-on message:&lt;br /&gt;
&lt;div class="small-text" id="premain1" style="cursor: pointer; width: 100%;"&gt;&lt;span id="precollapse1" preid="1" style="margin-bottom: 0pt;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;pre id="pre1" lang="cs" style="margin-top: 0pt;"&gt;ChannelMessageBuilder builder = &lt;span class="code-keyword"&gt;new&lt;/span&gt; ChannelMessageBuilder();

builder.Command = ChannelCommand.NoteOn;
builder.MidiChannel = &lt;span class="code-digit"&gt;0&lt;/span&gt;;
builder.Data1 = &lt;span class="code-digit"&gt;60&lt;/span&gt;;
builder.Data2 = &lt;span class="code-digit"&gt;127&lt;/span&gt;;
builder.Build();
Console.WriteLine(builder.Result);&lt;/pre&gt;After the builder has been initialized with the desired properties, the MIDI message          is built with a call to the &lt;code&gt;Build&lt;/code&gt; method. The MIDI message can          then be retrieved via the &lt;code&gt;Result&lt;/code&gt; property.&lt;br /&gt;
There are several builder classes for creating specific types of meta messages. For          example, to create a key signature meta message, you use the &lt;code&gt;KeySignatureBuilder&lt;/code&gt;         class:&lt;br /&gt;
&lt;div class="small-text" id="premain2" style="cursor: pointer; width: 100%;"&gt;&lt;span id="precollapse2" preid="2" style="margin-bottom: 0pt;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;pre id="pre2" lang="cs" style="margin-top: 0pt;"&gt;KeySignatureBuilder builder = &lt;span class="code-keyword"&gt;new&lt;/span&gt; KeySignatureBuilder();
builder.Key = Key.CMajor;
builder.Build();
Console.WriteLine(builder.Result);&lt;/pre&gt;&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h3&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Dispatcher"&gt;MessageDispatcher class&lt;/a&gt;&lt;/h3&gt;Often there is a need to process a collection of &lt;code&gt;IMidiMessage&lt;/code&gt;s. How          each message is processed depends on its type. The problem is that you cannot          tell an &lt;code&gt;IMidiMessage&lt;/code&gt;'s type without an explicit check. The &lt;code&gt;IMidiMessage&lt;/code&gt;         provides a &lt;code&gt;MessageType&lt;/code&gt; property just for this purpose. However,          having to repeatedly check message types throughout your code can be          cumbersome.&lt;br /&gt;
The &lt;code&gt;MessageDispatch&lt;/code&gt; class is designed to automate these checks. This          class acts as a source for every type of MIDI message. It raises an event each          time it dispatches a message. The type of event is determined by the type of          message it is dispatching.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Clock"&gt;Clocks&lt;/a&gt;&lt;/h2&gt;MIDI playback is driven by ticks that occur periodically. The source of these ticks          are MIDI clocks. MIDI clocks come in all shapes and sizes. For example,          playback can be driven by an internal or external clock. Also, the way in which          the ticks are generated depends on whether the MIDI sequence has pulses per          quarter note resolution or SMPTE resolution. For the vast majority of          situations, an internal clock generating ticks with pulses per quarter note          resolution is all you need.&lt;br /&gt;
The &lt;code&gt;IClock&lt;/code&gt; interface represents the basic functionality for all MIDI          clocks:&lt;br /&gt;
&lt;div class="small-text" id="premain3" style="cursor: pointer; width: 100%;"&gt;&lt;span id="precollapse3" preid="3" style="margin-bottom: 0pt;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;pre id="pre3" lang="cs" style="margin-top: 0pt;"&gt;&lt;span class="code-keyword"&gt;public&lt;/span&gt; &lt;span class="code-keyword"&gt;interface&lt;/span&gt; IClock
{
    &lt;span class="code-keyword"&gt;event&lt;/span&gt; EventHandler Tick;
    &lt;span class="code-keyword"&gt;event&lt;/span&gt; EventHandler Started;
    &lt;span class="code-keyword"&gt;event&lt;/span&gt; EventHandler Continued;
    &lt;span class="code-keyword"&gt;event&lt;/span&gt; EventHandler Stopped;
    &lt;span class="code-keyword"&gt;bool&lt;/span&gt; IsRunning
    {
        &lt;span class="code-keyword"&gt;get&lt;/span&gt;;
    }
}&lt;/pre&gt;The &lt;code&gt;Tick&lt;/code&gt; event occurs when a MIDI tick has elapsed. The &lt;code&gt;Started&lt;/code&gt;,         &lt;code&gt;Continued&lt;/code&gt;, and &lt;code&gt;Stopped&lt;/code&gt; events are self-explanatory.          However, it should be pointed out that when the &lt;code&gt;Started&lt;/code&gt; event          occurs, sequence playback starts from the beginning of the sequence. When the &lt;code&gt;             Continued&lt;/code&gt; event occurs, playback starts from the current position.          The &lt;code&gt;IsRunning&lt;/code&gt; property indicates whether the clock is running.&lt;br /&gt;
You may notice that there are no methods in the interface for starting and stopping          a clock. That is because with clocks that are driven by an external source, the          source is responsible for starting and stopping the clock. The clocks receive          messages via MIDI and based on those messages starts or stops generating ticks.          Since all MIDI clocks implement &lt;code&gt;IClock&lt;/code&gt;, it only represents the          functionality common to all the clocks.&lt;br /&gt;
At this time, the toolkit provides only one clock class, the &lt;code&gt;MidiInternalClock&lt;/code&gt;.          This clock generates MIDI ticks internally using pulses per quarter note          resolution. For the majority of situations, this clock will work fine.&lt;br /&gt;
The &lt;code&gt;MidiInternalClock&lt;/code&gt; has a &lt;code&gt;Tempo&lt;/code&gt; property for setting the          tempo in microseconds per beat. To set the tempo to 120 bpm, for example, you          would set the &lt;code&gt;Tempo&lt;/code&gt; property to 500000. It can receive meta tempo          change messages. When a meta tempo change message is passed to it, it changes          its tempo to match the tempo represented by the message.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="MidiEvent"&gt;MidiEvent class&lt;/a&gt;&lt;/h2&gt;A MIDI file is made up of several tracks. Each track contains one or more          timestamped MIDI messages. The timestamp represents the number of ticks since          the last message was played. This timestamp is called delta ticks. The &lt;code&gt;MidiEvent&lt;/code&gt;         class represents a timestamped MIDI message. It has three &lt;code lang="cs"&gt;&lt;span class="code-keyword"&gt;public&lt;/span&gt;&lt;/code&gt;         properties:&lt;br /&gt;
&lt;ul class="property"&gt;&lt;li&gt;             &lt;code&gt;DeltaTicks&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;AbsoluteTicks&lt;/code&gt;         &lt;/li&gt;
&lt;li&gt;             &lt;code&gt;MidiMessage&lt;/code&gt;         &lt;/li&gt;
&lt;/ul&gt;The &lt;code&gt;DeltaTicks&lt;/code&gt; property represents the number of ticks since the last &lt;code&gt;             MidiEvent&lt;/code&gt;. In other words, this value represents how long to wait          after playing the previous &lt;code&gt;MidiEvent&lt;/code&gt; before playing the current &lt;code&gt;MidiEvent&lt;/code&gt;.          For example, if the &lt;code&gt;DeltaTicks&lt;/code&gt; value is 10, we would allow 10          ticks to elapse before playing the MIDI message represented by the current &lt;code&gt;MidiEvent&lt;/code&gt;.&lt;br /&gt;
The &lt;code&gt;AbsoluteTicks&lt;/code&gt; represents the overall position of the &lt;code&gt;MidiEvent&lt;/code&gt;.          This is the total number of ticks that have elapsed until the current &lt;code&gt;MidiEvent&lt;/code&gt;.&lt;br /&gt;
The &lt;code&gt;MidiMessage&lt;/code&gt; property is the &lt;code&gt;IMidiMessage&lt;/code&gt; represented          by the &lt;code&gt;MidiEvent&lt;/code&gt;.&lt;br /&gt;
In addition there are two internal properties, one which points to the previous &lt;code&gt;MidiEvent&lt;/code&gt;         in the track, and one which points to the next &lt;code&gt;MidiEvent&lt;/code&gt; in the          track. In other words, the &lt;code&gt;MidiEvent&lt;/code&gt; class acts as a node in a          doubly linked list of &lt;code&gt;MidiEvent&lt;/code&gt;s.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Track"&gt;Track class&lt;/a&gt;&lt;/h2&gt;The &lt;code&gt;Track&lt;/code&gt; class represents a collection of &lt;code&gt;MidiEvent&lt;/code&gt;s. It          is responsible for maintaining a collection of &lt;code&gt;MidiEvent&lt;/code&gt;s in          proper order. &lt;code&gt;MidiEvent&lt;/code&gt;s are not directly added to a &lt;code&gt;Track&lt;/code&gt;.          Instead, you add an &lt;code&gt;IMidiMessage&lt;/code&gt;, specifying its absolute position          in the &lt;code&gt;Track&lt;/code&gt;. The &lt;code&gt;Track&lt;/code&gt; then creates a &lt;code&gt;MidiEvent&lt;/code&gt;         to represent the message and inserts it into its collection of &lt;code&gt;MidiEvent&lt;/code&gt;s.&lt;br /&gt;
In addition to providing functionality for adding and removing MIDI events, the &lt;code&gt;Track&lt;/code&gt;         class also provides several iterators. There is a standard iterator that simply          iterates over the &lt;code&gt;MidiEvent&lt;/code&gt;s one at a time. Another iterator takes          a &lt;code&gt;MessageDispatcher&lt;/code&gt; object and passes each &lt;code&gt;IMidiMessage&lt;/code&gt;         to the dispatcher which in turn raises an event specific to the type of message          it is dispatching. The value the iterator returns is the absolute ticks for the          current &lt;code&gt;MidiEvent&lt;/code&gt;.&lt;br /&gt;
Perhaps the most useful iterator is the one that when advanced moves forward only          one tick at a time. The iterator keeps track of its tick position in the &lt;code&gt;Track&lt;/code&gt;.          When the tick count has reached a value in which it is time to play the next &lt;code&gt;MidiEvent&lt;/code&gt;,          it passes the &lt;code&gt;IMidiMessage&lt;/code&gt; represented by the &lt;code&gt;MidiEvent&lt;/code&gt;         to the &lt;code&gt;MessageDispatcher&lt;/code&gt; and returns the absolute tick count. This          iterator also takes a &lt;code&gt;ChannelChaser&lt;/code&gt; object as well as a start          position value and "chases" up to the start position before switching to the          playback mode. In essence, this iterator allows us to stream the &lt;code&gt;Track&lt;/code&gt;         in real-time.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Sequence"&gt;Sequence class&lt;/a&gt;&lt;/h2&gt;The &lt;code&gt;Sequence&lt;/code&gt; class represents a collection of &lt;code&gt;Track&lt;/code&gt;s. It          also provides functionality for loading and saving MIDI files, so &lt;code&gt;Sequence&lt;/code&gt;s          can load and save themselves.&lt;br /&gt;
Every &lt;code&gt;Sequence&lt;/code&gt; has a division value. This value represents the          resolution of the &lt;code&gt;Sequence&lt;/code&gt; and is represented by a property. There          are two types of division values: Pulses per quarter note and SMPTE. The &lt;code&gt;Sequence&lt;/code&gt;         has a &lt;code&gt;SequenceType&lt;/code&gt; property indicating the sequence type.          Unfortunately, SMPTE sequences aren't supported at this time.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Devices"&gt;MIDI devices&lt;/a&gt;&lt;/h2&gt;There are several MIDI device classes in the toolkit. Each device class is          derived directly or indirectly from the abstract &lt;code&gt;Device&lt;/code&gt; class in          the &lt;code&gt;Sanford.Multimedia&lt;/code&gt; namespace. The &lt;code&gt;InputDevice&lt;/code&gt; class          represents a MIDI device capable of receiving MIDI messages from an external          source, such as a MIDI keyboard controller or synthesizer. The &lt;code&gt;OutputDeviceBase&lt;/code&gt;         class is an &lt;code&gt;&lt;span class="code-keyword"&gt;abstract&lt;/span&gt;&lt;/code&gt; class that serves as the base class          for the output device classes. The &lt;code&gt;OutputDevice&lt;/code&gt; class represents a          MIDI device capable of sending MIDI messages to an external source or your          soundcard. And the &lt;code&gt;OutputStream&lt;/code&gt; class encapsulates the Windows          Multimedia MIDI output stream API. It is capable of playing back timestamped          MIDI messages.&lt;br /&gt;
There can be more than one of these devices present on your computer. To determine          the number of input devices present, for example, you would query the &lt;code&gt;InputDevice&lt;/code&gt;'s         &lt;code lang="cs"&gt;&lt;span class="code-keyword"&gt;static&lt;/span&gt;&lt;/code&gt; &lt;code&gt;DeviceCount&lt;/code&gt; property. The output          device classes also have this property.&lt;br /&gt;
Each MIDI device has its own unique ID. This is simply an integer value representing          the device's order in the list of devices available. For example, the first          output device on your system would have an ID of 0. The second output device          would have an ID of 1, and so on. The same is true for the input devices. When          you create a MIDI device, you pass it the ID of the device you wish to use to          its constructor. If there was an error in opening the device, an exception is          thrown.&lt;br /&gt;
To find out the capabilities of a device, you query the class' &lt;code&gt;&lt;span class="code-keyword"&gt;static&lt;/span&gt;&lt;/code&gt;         &lt;code&gt;GetDeviceCapabilities&lt;/code&gt; method, passing it the device ID of the          device you are interested in. This method will return a structure filled with          values representing the capabilities of the specified MIDI device.&lt;br /&gt;
Let's describe each device class in detail:&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h3&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Input"&gt;InputDevice class&lt;/a&gt;&lt;/h3&gt;The &lt;code&gt;InputDevice&lt;/code&gt; class represents a MIDI device capable of receiving          MIDI messages. It has an event for each of the major MIDI message it can          receive. To receive MIDI messages, you connect to one or more of these events.          Then you call the &lt;code&gt;StartRecording&lt;/code&gt; method. Recording will continue          until either &lt;code&gt;StopRecording&lt;/code&gt; or &lt;code&gt;Reset&lt;/code&gt; is called. The &lt;code&gt;InputDevice&lt;/code&gt;         lets you set the size of the sysex buffer it uses to receive sysex messages.          When the &lt;code&gt;InputDevice&lt;/code&gt; has received a complete sysex message, it          raises the SysExReceived event.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h3&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="OutputBase"&gt;OutputDeviceBase class&lt;/a&gt;&lt;/h3&gt;The &lt;code&gt;OutputDeviceBase&lt;/code&gt; class is an &lt;code&gt;&lt;span class="code-keyword"&gt;abstract&lt;/span&gt;&lt;/code&gt; class          that provides basic functionality for sending MIDI messages. It has several          overloaded &lt;code&gt;Send&lt;/code&gt; methods for sending various types of MIDI          messages.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h3&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Output"&gt;OutputDevice class&lt;/a&gt;&lt;/h3&gt;The &lt;code&gt;OutputDevice&lt;/code&gt; class represents a MIDI device capable of sending MIDI          messages. It inherits most of its functionality from the &lt;code&gt;OutputDeviceBase&lt;/code&gt;         class. It also provides running status functionality.&lt;br /&gt;
The following code creates an &lt;code&gt;OutputDevice&lt;/code&gt;, builds and sends a note-on          message, sleeps for one second, and then builds and sends a note-off message:&lt;br /&gt;
&lt;div class="small-text" id="premain4" style="cursor: pointer; width: 100%;"&gt;&lt;span id="precollapse4" preid="4" style="margin-bottom: 0pt;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;pre id="pre4" lang="cs" style="margin-top: 0pt;"&gt;&lt;span class="code-keyword"&gt;using&lt;/span&gt;(OutputDevice outDevice = &lt;span class="code-keyword"&gt;new&lt;/span&gt; OutputDevice(&lt;span class="code-digit"&gt;0&lt;/span&gt;))
{
    ChannelMessageBuilder builder = &lt;span class="code-keyword"&gt;new&lt;/span&gt; ChannelMessageBuilder();

    builder.Command = ChannelCommand.NoteOn;
    builder.MidiChannel = &lt;span class="code-digit"&gt;0&lt;/span&gt;;
    builder.Data1 = &lt;span class="code-digit"&gt;60&lt;/span&gt;;
    builder.Data2 = &lt;span class="code-digit"&gt;127&lt;/span&gt;;
    builder.Build();

    outDevice.Send(builder.Result);

    Thread.Sleep(&lt;span class="code-digit"&gt;1000&lt;/span&gt;);

    builder.Command = ChannelCommand.NoteOff;
    builder.Data2 = &lt;span class="code-digit"&gt;0&lt;/span&gt;;
    builder.Build();

    outDevice.Send(builder.Result);
}&lt;/pre&gt;&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h3&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Stream"&gt;OutputStream class&lt;/a&gt;&lt;/h3&gt;The &lt;code&gt;OutputStream&lt;/code&gt; class is also derived from the &lt;code&gt;OutputDeviceBase&lt;/code&gt;         class. It encapsulates the Windows multimedia MIDI output stream API. It          provides functionality for playing back MIDI messages.&lt;br /&gt;
To play MIDI messages, you call &lt;code&gt;StartPlaying&lt;/code&gt;. The &lt;code&gt;OutputStream&lt;/code&gt;         will then begin playing back any MIDI messages in its queue. To place MIDI          messages in the queue, you first write one or more &lt;code&gt;MidiEvent&lt;/code&gt;s          using the &lt;code&gt;Write&lt;/code&gt; method. After writing the desired number of &lt;code&gt;MidiEvent&lt;/code&gt;s,          you call &lt;code&gt;Flush&lt;/code&gt;. This flushes the events to the stream causing it          to play them back.&lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Sequencer"&gt;Sequencer Class&lt;/a&gt;&lt;/h2&gt;The &lt;code&gt;Sequencer&lt;/code&gt; class is back. It's a lightweight class for playing back &lt;code&gt;             Sequence&lt;/code&gt;s. I felt the previous &lt;code&gt;MidiFilePlayer&lt;/code&gt; class was          not the best means for playing back MIDI sequences. I wanted to give the          toolkit the ability to play &lt;code&gt;Sequence&lt;/code&gt;s your create programmatically.          One issue that caused me to shy away from a &lt;code&gt;Sequencer&lt;/code&gt; class (after          having created one in earlier versions) is the problem of a &lt;code&gt;Sequence&lt;/code&gt;         changing as it's being played by a &lt;code&gt;Sequencer&lt;/code&gt;. I still haven't          solved that problem, but I didn't want that issue to prevent easy &lt;code&gt;Sequence&lt;/code&gt;         playback. So I'm putting in a new version of the &lt;code&gt;Sequencer&lt;/code&gt; class          with the understanding that it's meant to be used for simple playback. For          something more sophisticated, you can use it as the basis for creating          something more.     &lt;br /&gt;
&lt;a href="http://www.codeproject.com/KB/audio-video/MIDIToolkit.aspx#top"&gt;&lt;br /&gt;
&lt;/a&gt;&lt;br /&gt;
&lt;h2&gt;&lt;a href="http://www.blogger.com/post-create.g?blogID=6921611210899688855" id="Dependencies"&gt;Dependencies&lt;/a&gt;&lt;/h2&gt;The MIDI toolkit depends on the &lt;code&gt;DelegateQueue&lt;/code&gt; class from my &lt;code&gt;Sanford.Threading&lt;/code&gt;         namespace; the &lt;code&gt;InputDevice&lt;/code&gt; and &lt;code&gt;OutputDevice&lt;/code&gt; classes          use it for queueing MIDI events. In turn, the &lt;code&gt;Sanford.Threading&lt;/code&gt; namespace          depends on my &lt;code&gt;Sanford.Collection&lt;/code&gt; namespace, so that assembly is          also necessary for the toolkit to compile. Finally, the toolkit uses the &lt;code&gt;Sanford.Multimedia&lt;/code&gt;         namespace. I've provided all of the assemblies with the download. I've linked          the projects that use them to the assemblies in hopes that the toolkit will          compile out of the box. Hopefully, the days of having trouble compiling my          projects because of not having the right assemblies are over.&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/03/c-midi.html</link><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" height="72" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibV3Gsub-WicN31S4JaG-kzkjTOLUX_KO9R9BWbC1uq0rf5g3kwnuMBN85GVzrkx-LxgbveK2MlqQ_W8qCZjZ3VQ6LPX-ohD4DYbcMIeUJWodTM_BHyL13M5EiXrMxyOtG_jsik5e0AU46/s72-c/SequencerDemo.png" width="72"/><thr:total>1</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-7426960508971805511</guid><pubDate>Wed, 10 Mar 2010 06:43:00 +0000</pubDate><atom:updated>2010-03-09T22:43:14.389-08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">DBMS</category><title>DBMS: Indexes By Abdul Malik</title><description>&lt;div class="MsoNormal"&gt;&lt;a href="" name="_Toc67114517"&gt;&lt;span class="apple-style-span"&gt;&lt;b&gt;&lt;span style="color: black; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 20.0pt; line-height: 115%;"&gt;DBMS&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;b&gt;&lt;/b&gt;&lt;/a&gt;&lt;span class="apple-style-span"&gt;&lt;b&gt;&lt;span style="color: black; font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 20.0pt; line-height: 115%;"&gt;: Indexes By Abdul Malik&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;A database index is a data structure that improves the speed of data retrieval operations on a database table at the cost of slower writes and increased storage space. &lt;span style="background: yellow; mso-highlight: yellow;"&gt;Indexes can be created using one or more columns of a database table&lt;/span&gt;, providing the basis for both &lt;span style="background: yellow; mso-highlight: yellow;"&gt;rapid random look ups&lt;/span&gt; and &lt;span style="background: yellow; mso-highlight: yellow;"&gt;efficient access&lt;/span&gt; of &lt;span style="background: yellow; mso-highlight: yellow;"&gt;ordered records&lt;/span&gt;. The disk space required to store the index is typically less than that required by the table (since indexes usually contain only the key-fields according to which the table is to be arranged, and excludes all the other details in the table), yielding the possibility to store indexes in memory for a table whose data is too large to store in memory.&lt;/div&gt;&lt;div class="MsoNormal"&gt;In a relational database, &lt;span style="background: yellow; mso-highlight: yellow;"&gt;an index is a copy of one part of a table&lt;/span&gt;. &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;Some databases extend the power of indexing by allowing indexes to be created on functions or expressions&lt;/span&gt;. For example, an index could be created on upper(last_name), which would only store the upper case versions of the last_name field in the index. Another option sometimes supported is the use of "filtered" indexes, where index entries are created only for those records that satisfy some conditional expression. A further aspect of flexibility is to permit indexing on user-defined functions, as well as expressions formed from an assortment of built-in functions.&lt;/div&gt;&lt;div class="MsoNormal"&gt;Indexes may be defined as &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;unique&lt;/span&gt; or &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;non-unique&lt;/span&gt;. A unique index acts as a constraint on the table by preventing duplicate entries in the index and thus, the backing table. &lt;span style="background: yellow; mso-highlight: yellow;"&gt;Microsoft SQL Server allows a unique index to contain a single NULL value&lt;/span&gt;.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Index Architecture&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;Index architectures can be classified &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;clustered&lt;/span&gt; or &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;unclustered&lt;/span&gt;.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Unclustered&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;span style="background: yellow; mso-highlight: yellow;"&gt;An unclustered index is structured in a way that doesn't correspond to the order of the actual data records&lt;/span&gt;. It resembles the words index at the back of a book. For this reason, it will perform worse than clustered indexes on ranged searches where the result set is large, since each result could cost an additional I/O-operation to get the actual data record. One can have any number of these kinds of indexes—all that is required is the space to store the index itself; one does not copy the actual data to create a new index.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Clustered&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;Clustering alters the data block into a certain distinct order to match the index&lt;/span&gt;, hence it is also an operation on the data storage blocks as well as on the index. An address book ordered by first name resembles a clustered index in its structure and purpose. The exact operation of database systems vary, but because storing data is very redundant the row data can only be stored in one order. &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;Therefore, only one clustered index can be created on a given database table&lt;/span&gt;. Clustered indexes can greatly increase overall speed of retrieval, but usually only where the &lt;span style="background: yellow; mso-highlight: yellow;"&gt;data is accessed sequentially&lt;/span&gt; in the same or reverse order of the clustered index, or when a range of items are selected.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;a href="" style="mso-comment-date: 20100310T1129; mso-comment-reference: AM_1;"&gt;&lt;span style="background: yellow; mso-highlight: yellow;"&gt;Since the physical records are in this sort order on disk&lt;/span&gt;&lt;/a&gt;&lt;span class="MsoCommentReference"&gt;&lt;span style="font-size: 8.0pt; line-height: 115%;"&gt;&lt;a class="msocomanchor" href="file:///E:/DATA/MALIK-001/TOPICS/MY-WRITTINGS/DBMS-Indexes.docx#_msocom_1" id="_anchor_1" language="JavaScript" name="_msoanchor_1" onmouseout="msoCommentHide('_com_1')" onmouseover="msoCommentShow('_anchor_1','_com_1')"&gt;[AM1]&lt;/a&gt;&lt;span style="mso-special-character: comment;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;, the next row item in the sequence is immediately before or after the last one, and so fewer data block reads are required. The primary feature of a &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;clustered index is therefore the ordering of the physical data rows in accordance with the index blocks that point to them&lt;/span&gt;. Some databases separate the data and index blocks into separate files, others put two completely different data blocks within the same physical file(s).&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Index implementations&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;Indexes can be implemented using a variety of data structures. Popular indexes include &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;balanced&lt;/span&gt;&lt;span style="background: red; mso-highlight: red;"&gt; &lt;span style="color: white; mso-themecolor: background1;"&gt;trees&lt;/span&gt;&lt;/span&gt;, B+ trees and &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;hashes&lt;/span&gt;.&lt;/div&gt;&lt;div class="MsoNormal"&gt;In Microsoft SQL Server, the leaf node of the clustered index corresponds to the actual data, not simply a pointer to data that resides elsewhere, as is the case with a non-clustered index. Each relation can have a single clustered index and many unclustered indexes.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Applications and limitations&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;Indexes are useful for many applications but come with some limitations. Consider the following SQL statement:&lt;/div&gt;&lt;div align="center" class="MsoNormal" style="text-align: center;"&gt;SELECT first_name FROM people WHERE last_name = 'Smith';.&lt;/div&gt;&lt;div class="MsoNormal"&gt;To process this statement without an index the database software must look at the &lt;b style="mso-bidi-font-weight: normal;"&gt;last_name&lt;/b&gt; column on every row in the table (this is known as a &lt;span style="background: red; color: white; mso-highlight: red; mso-themecolor: background1;"&gt;full table scan&lt;/span&gt;). With an index the database simply follows the &lt;a href="" style="mso-comment-date: 20100310T1138; mso-comment-reference: AM_2;"&gt;b-tree data structure &lt;/a&gt;&lt;span class="MsoCommentReference"&gt;&lt;span style="font-size: 8.0pt; line-height: 115%;"&gt;&lt;a class="msocomanchor" href="file:///E:/DATA/MALIK-001/TOPICS/MY-WRITTINGS/DBMS-Indexes.docx#_msocom_2" id="_anchor_2" language="JavaScript" name="_msoanchor_2" onmouseout="msoCommentHide('_com_2')" onmouseover="msoCommentShow('_anchor_2','_com_2')"&gt;[AM2]&lt;/a&gt;&lt;span style="mso-special-character: comment;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;until the Smith entry has been found; this is much less computationally expensive than a full table scan.&lt;/div&gt;&lt;div class="MsoNormal"&gt;Consider this SQL statement: &lt;/div&gt;&lt;div align="center" class="MsoNormal" style="text-align: center;"&gt;SELECT email_address FROM customers WHERE email_address LIKE '%@yahoo.com';.&lt;/div&gt;&lt;div class="MsoNormal"&gt;This query would yield an email address for every customer whose email address ends with "@yahoo.com", but even if the &lt;b style="mso-bidi-font-weight: normal;"&gt;email_address&lt;/b&gt; column has been indexed the database still must perform a full table scan. This is because the index is built with the assumption that words go from left to right. With a wildcard at the beginning of the search-term, the database software is unable to use the underlying b-tree data structure (in other words, the WHERE-clause is not sargable). This problem can be solved through the addition of another index created on reverse(&lt;b style="mso-bidi-font-weight: normal;"&gt;email_address&lt;/b&gt;) and a SQL query like this: &lt;/div&gt;&lt;div class="MsoNormal"&gt;SELECT email_address FROM customers WHERE reverse(email_address) LIKE reverse('%@yahoo.com');. This puts the wild-card at the right-most part of the query (now moc.oohay@%) which the index on reverse(email_address) can satisfy.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Types&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;Bitmap index&lt;/div&gt;&lt;div class="MsoNormal"&gt;A bitmap index is a special kind of index that stores the bulk of its data as bit arrays (bitmaps) and answers most queries by performing bitwise logical operations on these bitmaps. The most commonly used index, such as B+trees, are most efficient if the values it indexes do not repeat or repeat a smaller number of times. In contrast, the bitmap index is designed for cases where the values of a variable repeat very frequently. For example, the gender field in a customer database usually contains two distinct values: male or female. For such variables, the bitmap index can have a significant performance advantage over the commonly used trees.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Dense index&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;A dense index in databases is a file with pairs of keys and pointers for every record in the data file. Every key in this file is associated with a particular pointer to a record in the sorted data file. In clustered indexes with duplicate keys, the dense index points to the first record with that key.[4]&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Sparse index&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;A sparse index in databases is a file with pairs of keys and pointers for every block in the data file. Every key in this file is associated with a particular pointer to the block in the sorted data file. In clustered indexes with duplicate keys, the sparse index points to the lowest search key in each block.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Reverse index&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;A reverse key index reverses the key value before entering it in the index. E.g., the value 24538 becomes 83542 in the index. Reversing the key value is particularly useful for indexing data such as sequence numbers, where new key values monotonically increase.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;b style="mso-bidi-font-weight: normal;"&gt;Covering Index&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal"&gt;In most cases, an index is used to quickly locate the data record(s) from which the required data is read. In other words, the index is only used to locate data records in the table and not to return data.&lt;/div&gt;&lt;div class="MsoNormal"&gt;A covering index is a special case where the index itself contains the required data field(s) and can return the data.&lt;/div&gt;&lt;div class="MsoNormal"&gt;Consider the following table (other fields omitted):&lt;/div&gt;&lt;table border="1" cellpadding="0" cellspacing="0" class="MsoNormalTable" style="background: #F9F9F9; border-collapse: collapse; border: none; mso-border-alt: solid #AAAAAA .5pt; mso-yfti-tbllook: 1184;"&gt;&lt;tbody&gt;
&lt;tr style="height: 19.6pt; mso-yfti-firstrow: yes; mso-yfti-irow: 0;"&gt;   &lt;td style="background: #F2F2F2; border: solid #AAAAAA 1.0pt; height: 19.6pt; mso-border-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div align="center" class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt; text-align: center;"&gt;&lt;b&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;ID&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="background: #F2F2F2; border-left: none; border: solid #AAAAAA 1.0pt; height: 19.6pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div align="center" class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt; text-align: center;"&gt;&lt;b&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Name&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="background: #F2F2F2; border-left: none; border: solid #AAAAAA 1.0pt; height: 19.6pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div align="center" class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt; text-align: center;"&gt;&lt;b&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Other Fields&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 1;"&gt;   &lt;td style="border-top: none; border: solid #AAAAAA 1.0pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;12&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #AAAAAA 1.0pt; border-left: none; border-right: solid #AAAAAA 1.0pt; border-top: none; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Plug&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #AAAAAA 1.0pt; border-left: none; border-right: solid #AAAAAA 1.0pt; border-top: none; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;...&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="height: 1.2pt; mso-yfti-irow: 2;"&gt;   &lt;td style="border-top: none; border: solid #AAAAAA 1.0pt; height: 1.2pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;13&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #AAAAAA 1.0pt; border-left: none; border-right: solid #AAAAAA 1.0pt; border-top: none; height: 1.2pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Lamp&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #AAAAAA 1.0pt; border-left: none; border-right: solid #AAAAAA 1.0pt; border-top: none; height: 1.2pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;...&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="height: 7.45pt; mso-yfti-irow: 3; mso-yfti-lastrow: yes;"&gt;   &lt;td style="border-top: none; border: solid #AAAAAA 1.0pt; height: 7.45pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;14&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #AAAAAA 1.0pt; border-left: none; border-right: solid #AAAAAA 1.0pt; border-top: none; height: 7.45pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Fuse&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #AAAAAA 1.0pt; border-left: none; border-right: solid #AAAAAA 1.0pt; border-top: none; height: 7.45pt; mso-border-alt: solid #AAAAAA .5pt; mso-border-left-alt: solid #AAAAAA .5pt; mso-border-top-alt: solid #AAAAAA .5pt; padding: 2.4pt 2.4pt 2.4pt 2.4pt;"&gt;   &lt;div class="MsoNormal" style="line-height: normal; margin-bottom: 12.0pt; margin-left: 0in; margin-right: 0in; margin-top: 12.0pt;"&gt;&lt;span style="color: black; font-family: &amp;quot;Times New Roman&amp;quot;,&amp;quot;serif&amp;quot;; font-size: 12.0pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;...&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;div class="MsoNormal" style="line-height: 18.0pt; margin-bottom: 6.0pt; margin-left: 0in; margin-right: 0in; margin-top: 4.8pt;"&gt;To find the Name for ID 13, an index on (ID) will be useful, but the record must still be read to get the Name. However, an index on (ID, Name) contains the required data field and eliminates the need to look up the record.&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 18.0pt; margin-bottom: 6.0pt; margin-left: 0in; margin-right: 0in; margin-top: 4.8pt;"&gt;A covering index can dramatically speed up data retrieval but may itself be large due to the additional keys, which slows down data insertion &amp;amp; update. To reduce such index size, some systems allow non-key fields to be included in the index. Non-key fields are not themselves part of the index ordering but only included at the leaf level, allowing for a covering index with less overall index size.&lt;/div&gt;&lt;div class="MsoNormal"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="mso-element: comment-list;"&gt;  &lt;hr align="left" class="msocomoff" size="1" width="33%" /&gt;    &lt;div style="mso-element: comment;"&gt;  &lt;div class="msocomtxt" id="_com_1" language="JavaScript" onmouseout="msoCommentHide('_com_1')" onmouseover="msoCommentShow('_anchor_1','_com_1')"&gt;&lt;span style="mso-comment-author: &amp;quot;Abdul Malik&amp;quot;;"&gt;&lt;a href="" name="_msocom_1"&gt;&lt;/a&gt;&lt;/span&gt;  &lt;div class="MsoCommentText"&gt;&lt;span class="MsoCommentReference"&gt;&lt;span style="font-size: 8.0pt;"&gt;&lt;span style="mso-special-character: comment;"&gt;&amp;nbsp;&lt;a class="msocomoff" href="file:///E:/DATA/MALIK-001/TOPICS/MY-WRITTINGS/DBMS-Indexes.docx#_msoanchor_1"&gt;[AM1]&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="background: yellow; mso-highlight: yellow;"&gt;Usman – Plz comment on this statement.&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="mso-element: comment;"&gt;  &lt;div class="msocomtxt" id="_com_2" language="JavaScript" onmouseout="msoCommentHide('_com_2')" onmouseover="msoCommentShow('_anchor_2','_com_2')"&gt;&lt;span style="mso-comment-author: &amp;quot;Abdul Malik&amp;quot;;"&gt;&lt;a href="" name="_msocom_2"&gt;&lt;/a&gt;&lt;/span&gt;  &lt;div class="MsoCommentText"&gt;&lt;span class="MsoCommentReference"&gt;&lt;span style="font-size: 8.0pt;"&gt;&lt;span style="mso-special-character: comment;"&gt;&amp;nbsp;&lt;a class="msocomoff" href="file:///E:/DATA/MALIK-001/TOPICS/MY-WRITTINGS/DBMS-Indexes.docx#_msoanchor_2"&gt;[AM2]&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;This should be discussed&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/03/dbms-indexes-by-abdul-malik.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-265573736438408553</guid><pubDate>Fri, 26 Feb 2010 09:31:00 +0000</pubDate><atom:updated>2010-02-26T01:33:30.734-08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Architecture</category><title>Audit Trail System</title><description>&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjo3IkwyoCItZguVYvbsQm_Bjar7RMx5Qp1PdGLJbT3KHfyhpdAZOaiUxv6DarGu_yEnRIk4ctYcBd0hQY6-k11QbwCTlG-gA0sUnC_8-UXthQtrWeVzZMwRl_t9Hg-INEcjKnvk1v4OtIb/s1600-h/001A.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjo3IkwyoCItZguVYvbsQm_Bjar7RMx5Qp1PdGLJbT3KHfyhpdAZOaiUxv6DarGu_yEnRIk4ctYcBd0hQY6-k11QbwCTlG-gA0sUnC_8-UXthQtrWeVzZMwRl_t9Hg-INEcjKnvk1v4OtIb/s320/001A.JPG" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: left;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; mso-outline-level: 2;"&gt;&lt;b&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 13pt;"&gt;Introduction&lt;/span&gt;&lt;/b&gt;&lt;b&gt;&lt;span style="font-family: 'Times New Roman', serif; font-size: 13pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;There are multiple reasons to have an Audit trail System in your application. Some companies have to do it because of their rigid / un-professional enviroment, such as JGC-DESCON ENGINEERING PVT. LTD. But on the other end it is very useful for debugging purpose. It shows you what was in your database at any point in time.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;In this article I will explain the method I prefer for implementing an audit trail. Next, I will introduce a script to automate the implementation of the audit trail in the database.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; mso-outline-level: 2;"&gt;&lt;b&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 13pt;"&gt;Audit Trail With Triggers&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;So how to implement an audit trail? Different visions exist. The one I prefer is to use a shadow table for each table that exists in the database. Every time a record is inserted, updated or deleted in a table, the record is also inserted in the corresponding shadow table. For inserting the record in the shadow table too, I use triggers on the original table that will fire whenever something happens. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;Let's make this clear with a small example.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh-Gk4ukJsABgdR8Hx6ZgZJ7qSZu2b9rAfphd1bA_FtN-c-4EQ12-xV6k_NoJRH21sEQm2xO106IrTx5Kjd1usGvVQ1Zj98AsIpR8daqymetNVpCCkiV7LYyxKPtDRt61uHzEB-ODNv_Blz/s1600-h/001B.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh-Gk4ukJsABgdR8Hx6ZgZJ7qSZu2b9rAfphd1bA_FtN-c-4EQ12-xV6k_NoJRH21sEQm2xO106IrTx5Kjd1usGvVQ1Zj98AsIpR8daqymetNVpCCkiV7LYyxKPtDRt61uHzEB-ODNv_Blz/s320/001B.JPG" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: left;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana; font-size: 13px;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;On the left side, you see the structure of a table called&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;Employee&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;containing five columns. I refer to this table as the base table. On the right, you see the shadow table for this table. The shadow table contains all columns from the&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;Employee&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;table, plus some extra columns:&lt;/span&gt;&lt;span style="font-family: 'Times New Roman', serif; font-size: 10pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;ul type="disc"&gt;&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l3 level1 lfo1; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditId&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: This the primary key of the shadow      table. It is an identity field.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l3 level1 lfo1; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditAction&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: This is a one letter code to      indicate the kind of operation. Values are&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;I&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;,&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;U&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;or&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;D&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;,      for insert, update and delete respectively.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l3 level1 lfo1; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditDate&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: The date and time when the      action occurred. The default value is set to&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;getdate()&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;, an SQL function that returns the      current date and time.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l3 level1 lfo1; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditUser&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: The user who performed the      action. The default value is set to&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;suser_sname()&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;, an SQL function that returns the      user name of the user currently connected.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l3 level1 lfo1; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditApp&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: The application that was used.      The default value is set to&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;((&lt;/span&gt;&lt;span style="color: purple; font-family: 'Courier New';"&gt;'App=('&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;+rtrim(isnull(app_name(),&lt;/span&gt;&lt;span style="color: purple; font-family: 'Courier New';"&gt;''&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;)))+&lt;/span&gt;&lt;span style="color: purple; font-family: 'Courier New';"&gt;') '&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;)&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;.      This allows you to tell which application was used to modify the data,      e.g.&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;App=(Microsoft SQL Server Management Studio Express)&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;To fill up the shadow table, I define triggers on the&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;Employee&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;table. We need three triggers: one for inserts, one for updates, and one for deletes. The code for the insert action is shown below. Those for updates and deletes are similar. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 9.95pt; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana; font-size: 11px;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 10pt;"&gt;CREATE&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; &lt;span style="color: blue;"&gt;TRIGGER&lt;/span&gt; tr_Employee_Insert &lt;span style="color: blue;"&gt;ON&lt;/span&gt; dbo&lt;span style="color: grey;"&gt;.&lt;/span&gt;Employee&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 10pt;"&gt;FOR&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; &lt;span style="color: blue;"&gt;INSERT&lt;/span&gt; &lt;span style="color: blue;"&gt;AS&lt;/span&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 10pt;"&gt;INSERT&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; &lt;span style="color: blue;"&gt;INTO&lt;/span&gt; Employee_shadow&lt;span style="color: grey;"&gt;(&lt;/span&gt;ID&lt;span style="color: grey;"&gt;,&lt;/span&gt; FNAME&lt;span style="color: grey;"&gt;,&lt;/span&gt; LNAME&lt;span style="color: grey;"&gt;,&lt;/span&gt; PHONE&lt;span style="color: grey;"&gt;,&lt;/span&gt; EMAIL&lt;span style="color: grey;"&gt;,&lt;/span&gt;AuditAction&lt;span style="color: grey;"&gt;) &lt;/span&gt;&lt;span style="color: blue;"&gt;SELECT&lt;/span&gt; ID&lt;span style="color: grey;"&gt;,&lt;/span&gt; FNAME&lt;span style="color: grey;"&gt;,&lt;/span&gt; LNAME&lt;span style="color: grey;"&gt;,&lt;/span&gt; PHONE&lt;span style="color: grey;"&gt;,&lt;/span&gt; EMAIL&lt;span style="color: grey;"&gt;,&lt;/span&gt;&lt;span style="color: red;"&gt;'I'&lt;/span&gt; &lt;span style="color: blue;"&gt;FROM&lt;/span&gt; employee&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The columns that are filled up by the trigger are only the data columns from the base table (&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt;ID&lt;span style="color: grey;"&gt;,&lt;/span&gt; FNAME&lt;span style="color: grey;"&gt;,&lt;/span&gt; LNAME&lt;span style="color: grey;"&gt;,&lt;/span&gt; PHONE&lt;span style="color: grey;"&gt;,&lt;/span&gt; EMAIL&lt;span style="color: grey;"&gt;,&lt;/span&gt;AuditAction&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;) and the&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditAction &lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;column. All other columns in the shadow table (&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditId&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;,&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditDate&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;,&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditUser&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;and&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;AuditApp&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;) are filled up by their default value definition.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;So what are the strengths and weaknesses of this approach? Let's start with the strengths:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;ul type="disc"&gt;&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l1 level1 lfo2; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;It completely      separates the current data from the audit trail. The old values are no      longer in the base table but in the shadow table. There are no soft      deletes, where deleted records are flagged as being deleted instead of      being actually deleted.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l1 level1 lfo2; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;It can easily be      implemented on existing databases. If originally you did not foresee audit      trailing, you can add it afterwards. The only thing you need to do is add      the triggers on the base tables and create the shadow table. No changes      have to be made to stored procedures or applications working with your      database.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l1 level1 lfo2; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;It always      triggers. E.g. if you connect to your database through Enterprise Manager      and you modify the data by hand, the triggers fire and the shadow table is      updated accordingly.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The method also has some drawbacks:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;ul type="disc"&gt;&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l2 level1 lfo3; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The entire      record is copied to the shadow table, including the columns that were not      changed. In our example, if you change the&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;firstname&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;of a user in the      base table, the&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;lastname&amp;nbsp;&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;is also copied to the shadow table      although it did not change. Hence, the shadow table will take up more      space than strictly needed.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l2 level1 lfo3; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;A trigger cannot      be used on all column data types.&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;Text&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;,&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;Ntext&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;,      and&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;Image&amp;nbsp;&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;are not supported. The reason is      that they are not stored in the record itself. The record only holds a      pointer to the data. In SQL 2005, the timestamp is not supported either.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l2 level1 lfo3; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The number of      tables doubles, although I personally don't find this an objection.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l2 level1 lfo3; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The audit trail      is on a table level instead of on an action level. If during a single save      operation in your application multiple tables in your database get      updated, there is no link between the different transactions that took      place on the different tables. The only thing that links them together is      that they occurred at (almost) the same moment and by the same user.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; mso-outline-level: 2;"&gt;&lt;b&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 13pt;"&gt;The Audit Trail Generator Script&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;If you have 50 tables in your database, adding an audit trail using the method just described means adding another 50 tables and creating 150 triggers. This is why I have created the audit trail generator. It saves time and avoids typo errors. See the link on top of this article to download the code.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The audit trail generator is written as a stored procedure. Hence, you don't need any other tools. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The stored procedure takes four arguments:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;ul type="disc"&gt;&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l0 level1 lfo4; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;@TableName&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: The name of the table to which      you want to add an audit trail, e.g.&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;users&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l0 level1 lfo4; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;@Owner&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: The owner of the table. The      default value is&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;dbo&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l0 level1 lfo4; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;@AuditNameExtention&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: The extension you want for the      shadow table name. E.g., if you set it to&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;_shadow&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;, the audit table for&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;users&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;will be called&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;users_shadow&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;. The default value is&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;_shadow&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="color: black; line-height: 14.4pt; mso-list: l0 level1 lfo4; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; tab-stops: list .5in;"&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;@DropAuditTable&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;: A bit to specify if the shadow      table can be dropped. If&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: navy; font-family: 'Courier New';"&gt;1&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;,      the existing audit table will be dropped and recreated. Of course, you      lose all data in there. This is especially useful when you are still in      development, but you may want to do this on a production system. The      default value is&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: navy; font-family: 'Courier New';"&gt;0&lt;/span&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 10pt;"&gt;.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The stored procedure will discover the columns in the original table by querying the system tables of SQL Server. These system tables are used by SQL Server itself to store the structure of the tables. The query to get all info about the table is shown below.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 10pt;"&gt;SELECT&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;name&lt;span style="color: grey;"&gt;,&lt;/span&gt; c&lt;span style="color: grey;"&gt;.&lt;/span&gt;name &lt;span style="color: blue;"&gt;as&lt;/span&gt; TypeName&lt;span style="color: grey;"&gt;,&lt;/span&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;&lt;span style="color: blue;"&gt;length&lt;/span&gt;&lt;span style="color: grey;"&gt;,&lt;/span&gt;b&lt;span style="color: grey;"&gt;.&lt;/span&gt;isnullable&lt;span style="color: grey;"&gt;,&lt;/span&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;collation&lt;span style="color: grey;"&gt;,&lt;/span&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;xprec&lt;span style="color: grey;"&gt;,&lt;/span&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;xscale&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 10pt;"&gt;FROM&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; &lt;span style="color: green;"&gt;sysobjects&lt;/span&gt; a&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: grey; font-family: 'Courier New'; font-size: 10pt;"&gt;inner&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; &lt;span style="color: grey;"&gt;join&lt;/span&gt; &lt;span style="color: green;"&gt;syscolumns&lt;/span&gt; b &lt;span style="color: blue;"&gt;on&lt;/span&gt; a&lt;span style="color: grey;"&gt;.&lt;/span&gt;id &lt;span style="color: grey;"&gt;=&lt;/span&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;id&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: grey; font-family: 'Courier New'; font-size: 10pt;"&gt;inner&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; &lt;span style="color: grey;"&gt;join&lt;/span&gt; &lt;span style="color: green;"&gt;systypes&lt;/span&gt; c &lt;span style="color: blue;"&gt;on&lt;/span&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;xtype &lt;span style="color: grey;"&gt;=&lt;/span&gt; c&lt;span style="color: grey;"&gt;.&lt;/span&gt;xtype &lt;span style="color: grey;"&gt;and&lt;/span&gt; c&lt;span style="color: grey;"&gt;.&lt;/span&gt;name &lt;span style="color: grey;"&gt;&amp;lt;&amp;gt;&lt;/span&gt; &lt;span style="color: red;"&gt;'sysname'&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 10pt;"&gt;WHERE&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; a&lt;span style="color: grey;"&gt;.&lt;/span&gt;id &lt;span style="color: grey;"&gt;=&lt;/span&gt; &lt;span style="color: magenta;"&gt;object_id&lt;/span&gt;&lt;span style="color: grey;"&gt;(&lt;/span&gt;&lt;span style="color: red;"&gt;N'Employee'&lt;/span&gt;&lt;span style="color: grey;"&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="color: grey; font-family: 'Courier New'; font-size: 10pt;"&gt;and&lt;/span&gt;&lt;span style="font-family: 'Courier New'; font-size: 10pt;"&gt; &lt;span style="color: magenta;"&gt;OBJECTPROPERTY&lt;/span&gt;&lt;span style="color: grey;"&gt;(&lt;/span&gt;a&lt;span style="color: grey;"&gt;.&lt;/span&gt;id&lt;span style="color: grey;"&gt;,&lt;/span&gt; &lt;span style="color: red;"&gt;N'IsUserTable'&lt;/span&gt;&lt;span style="color: grey;"&gt;)&lt;/span&gt; &lt;span style="color: grey;"&gt;=&lt;/span&gt; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&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 style="color: blue;"&gt;ORDER&lt;/span&gt; &lt;span style="color: blue;"&gt;BY&lt;/span&gt; b&lt;span style="color: grey;"&gt;.&lt;/span&gt;colId&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The image below shows the results if we launch this query for our&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;Employee&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;table.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQ4niuxmOhpJZYSbDISjAG9f7e3KFP0oFH9cfTIS4xLWa9awCMmY6KDAyzSbQ-Qcs98MSzcsicL6X3i5o8r-oe3p9-hIWIxzxWc66yemT2d4OHmxF_uNMGxRqx_gc8okU6-SDTK6PA7O_R/s1600-h/001C.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQ4niuxmOhpJZYSbDISjAG9f7e3KFP0oFH9cfTIS4xLWa9awCMmY6KDAyzSbQ-Qcs98MSzcsicL6X3i5o8r-oe3p9-hIWIxzxWc66yemT2d4OHmxF_uNMGxRqx_gc8okU6-SDTK6PA7O_R/s320/001C.JPG" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: left;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The remainder of the stored procedure loops over the result of this query using a cursor, and dynamically builds up the SQL statements in a string to create the shadow table and to add the triggers to the original table. These statements are then executed with the&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;EXEC&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;command. I will not go into the details of it, since it is straight forward.&lt;/span&gt;&lt;span style="font-family: 'Times New Roman', serif; font-size: 10pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; mso-outline-level: 2;"&gt;&lt;span class="Apple-style-span" style="color: #ff9900; font-size: 17px; font-weight: bold;"&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto; mso-outline-level: 2;"&gt;&lt;b&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 13pt;"&gt;Using the Script&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The script is a stored procedure, so using it means calling the stored procedure. In its simplest form, you only need to set the&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New';"&gt;@TableName&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;parameter because for all other parameters, default values have been specified. The following statement can be launched from a query window.&lt;/span&gt;&lt;br /&gt;
&lt;span class="Apple-style-span" style="font-family: Verdana; font-size: 13px;"&gt;&lt;span class="Apple-style-span" style="font-family: 'Times New Roman'; font-size: 16px; line-height: normal;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 9pt;"&gt;EXECUTE&lt;/span&gt;&lt;span style="color: black; font-family: 'Courier New'; font-size: 9pt;"&gt;&amp;nbsp;GenerateAudittrail&amp;nbsp;&lt;/span&gt;&lt;span style="color: purple; font-family: 'Courier New'; font-size: 9pt;"&gt;'Users'&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="background: #FBEDBB; line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; tab-stops: 45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana; font-size: 13px; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;The following example shows what it looks like if all parameter values are specified. &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;&lt;/span&gt;&lt;/div&gt;&lt;div class="MsoNormal" style="background: #FBEDBB; line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; tab-stops: 45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt;"&gt;&lt;span style="color: blue; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;EXECUTE&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt; GenerateAudittrail &lt;/span&gt;&lt;/span&gt;&lt;span style="color: purple; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;'Users'&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;, &lt;/span&gt;&lt;/span&gt;&lt;span style="color: purple; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;'dbo'&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;,&lt;/span&gt;&lt;/span&gt;&lt;span style="color: purple; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;'_shadow'&lt;/span&gt;&lt;/span&gt;&lt;span style="color: black; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;, &lt;/span&gt;&lt;/span&gt;&lt;span style="color: navy; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;span class="Apple-style-span" style="background-color: white;"&gt;0 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &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;&lt;/span&gt;&lt;span style="color: black; font-family: 'Courier New'; font-size: 9pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;The script is very handy to quickly create a shadow table for a given database table. However, it was not designed to modify a shadow table to reflect changes to the corresponding base table. In this case, it can only drop the shadow table, losing all records in it, and recreate it. Set the&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: #990000; font-family: 'Courier New'; font-size: 11pt;"&gt;@DropAuditTable&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;to&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: navy; font-family: 'Courier New'; font-size: 11pt;"&gt;1&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: black; font-family: Verdana, sans-serif; font-size: 10pt;"&gt;to force dropping and recreating the shadow table.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/02/audit-trail-system.html</link><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" height="72" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjo3IkwyoCItZguVYvbsQm_Bjar7RMx5Qp1PdGLJbT3KHfyhpdAZOaiUxv6DarGu_yEnRIk4ctYcBd0hQY6-k11QbwCTlG-gA0sUnC_8-UXthQtrWeVzZMwRl_t9Hg-INEcjKnvk1v4OtIb/s72-c/001A.JPG" width="72"/><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-8436731073685798926</guid><pubDate>Sun, 07 Feb 2010 18:29:00 +0000</pubDate><atom:updated>2010-02-07T10:29:01.679-08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Biztalk</category><title>Biztalk Server 2006 compatibility with Visual Studio 2008 (VS2008)</title><description>This is for all you guys who are trying to figure out whether Biztalk 2006 works with VS2008.&lt;br /&gt;
&lt;br /&gt;
I had this requirement in my project that we all migrate to .NET 3.5 environment / VS2008. Everything looked fine untill we realized that Biztalk 2006 is not supported by VS2008. I did a lot of reaseach in blogs and talking to Microsoft Support. The anwer is found was that &lt;strong&gt;"Biztalk Server 2006 will not work with VS2008".&lt;/strong&gt; In fact Biztalk is not compatible with any of the 2008 technologies including SQL Server 2008.&lt;br /&gt;
&lt;br /&gt;
I spoke to MS Tech. Support and they confirmed that there is no compatibility. It is expected that future versions of Biztalk (R3) will possibly support VS2008. They have no idea when it would be release, but the hint is that the CTP version might hit by the end of the year.&lt;br /&gt;
&lt;br /&gt;
I also tried out practically on my machine. I installed VS2008 on existing Biztalk setup, but VS2008 doesn't recognize ".BTPROJ". I even tried to install VS2008 first and then Biztalk, still the same issue.&lt;br /&gt;
&lt;br /&gt;
Its really so bad on Microsoft that Biztalk being such a advanced technology will not be a part of .NET Framework 3.5 environment for so long :(.&lt;br /&gt;
&lt;br /&gt;
Here is the response I got from Microsoft.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------------&lt;br /&gt;
Thank you for contacting Microsoft Sales Information today.&lt;br /&gt;
&lt;br /&gt;
Per our discussion, I've attached links/information that you requested below.&lt;br /&gt;
&lt;br /&gt;
From my research I have found that BizTalk Server 06 and Visual Studios 08 actually are not compatible. The .NET framework used by Visual Studios 08 to create applications is not compatible with the requirements of BizTalk Server 06; Microsoft may be releasing a Service Pack for BizTalk Server or a new BizTalk Server which will address this compatibility issue.&lt;br /&gt;
This blog on this Microsoft web site will outline more in-depth what I have just stated here.&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://blogs.msdn.com/stevemar/archive/2008/04/23/biztalk-server-platform-updates.aspx" title="http://blogs.msdn.com/stevemar/archive/2008/04/23/biztalk-server-platform-updates.aspx"&gt;http://blogs.msdn.com/stevemar/archive/2008/04/23/biztalk-server-platform-updates.aspx&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/02/biztalk-server-2006-compatibility-with.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-9032632187355369307</guid><pubDate>Thu, 21 Jan 2010 11:15:00 +0000</pubDate><atom:updated>2010-01-21T03:15:31.401-08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Architecture</category><title>Writting My Own WebServer</title><description>&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEga3CvJhHf3MunY7LfSOJGEtgaepMSBn3Fx-jsdS3Vk65hpCdyw04gl6Chp_23h81fbSaAg2yE6IvKn2uw0ey749VMNaw1Ng7FyzRtC4aTWg6hDaj0WaCUF7wOhY4ULUCC2HKdQvhozs_XV/s1600-h/MyServer.gif" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEga3CvJhHf3MunY7LfSOJGEtgaepMSBn3Fx-jsdS3Vk65hpCdyw04gl6Chp_23h81fbSaAg2yE6IvKn2uw0ey749VMNaw1Ng7FyzRtC4aTWg6hDaj0WaCUF7wOhY4ULUCC2HKdQvhozs_XV/s320/MyServer.gif" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;Still Working on it.... will post all the data shortly ........&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/01/writting-my-own-webserver.html</link><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" height="72" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEga3CvJhHf3MunY7LfSOJGEtgaepMSBn3Fx-jsdS3Vk65hpCdyw04gl6Chp_23h81fbSaAg2yE6IvKn2uw0ey749VMNaw1Ng7FyzRtC4aTWg6hDaj0WaCUF7wOhY4ULUCC2HKdQvhozs_XV/s72-c/MyServer.gif" width="72"/><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-9071549586519657071</guid><pubDate>Mon, 11 Jan 2010 11:11:00 +0000</pubDate><atom:updated>2010-01-11T03:11:33.428-08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Architecture</category><title>Interface Vs Abstract Class</title><description>&lt;table border="1" cellpadding="0" cellspacing="0" class="MsoNormalTable" style="border-bottom-style: none; border-collapse: collapse; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; width: 568px;"&gt;&lt;thead&gt;
&lt;tr style="mso-yfti-firstrow: yes; mso-yfti-irow: 0;"&gt;    &lt;td style="background: #EBF6FF; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;    &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;b&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Feature&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;    &lt;td style="background: #EBF6FF; border-left: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;    &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;b&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Interface&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;    &lt;td style="background: #EBF6FF; border-left: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;    &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;b&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Abstract    class&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;/tr&gt;
&lt;/thead&gt;  &lt;tbody&gt;
&lt;tr style="mso-yfti-irow: 1;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Multiple   inheritance&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;A   class may inherit several interfaces.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;A   class may inherit only one abstract class.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 2;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Default   implementation&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;An   interface cannot provide any code, just the signature.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;An   abstract class can provide complete, default code and/or just the details   that have to be overridden.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 3;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Access   Modfiers&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;An   interface cannot have access modifiers for the subs, functions, properties   etc everything is assumed as public&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;An   abstract class can contain access modifiers for the subs, functions,   properties&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 4;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Core   VS Peripheral&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Interfaces   are used to define the peripheral abilities of a class. In other words both   Human and Vehicle can inherit from a IMovable interface.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;An   abstract class defines the core identity of a class and there it is used for   objects of the same type.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 5;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="background: yellow; font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-highlight: yellow;"&gt;Homogeneity&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="background: yellow; font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-highlight: yellow;"&gt;If various implementations only share   method signatures then it is better to use Interfaces.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="background: yellow; font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-highlight: yellow;"&gt;If various implementations are of the   same kind and use common behaviour or status then abstract class is better to   use.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 6;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="background: yellow; font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-highlight: yellow;"&gt;Speed&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="background: yellow; font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-highlight: yellow;"&gt;Requires more time to find the actual   method in the corresponding classes.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="background: yellow; font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;; mso-highlight: yellow;"&gt;Fast&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 7;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Adding   functionality (Versioning)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;If   we add a new method to an Interface then we have to track down all the   implementations of the interface and define implementation for the new   method.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; mso-margin-bottom-alt: auto; mso-margin-top-alt: auto;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;If   we add a new method to an abstract class then we have the option of providing   default implementation and therefore all the existing code might work   properly.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;tr style="mso-yfti-irow: 8; mso-yfti-lastrow: yes;"&gt;   &lt;td style="border-top: none; border: solid #CCCCCC 1.0pt; mso-border-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;Fields   and Constants&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;No   fields can be defined in interfaces&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;   &lt;td style="border-bottom: solid #CCCCCC 1.0pt; border-left: none; border-right: solid #CCCCCC 1.0pt; border-top: none; mso-border-alt: solid #CCCCCC .75pt; mso-border-left-alt: solid #CCCCCC .75pt; mso-border-top-alt: solid #CCCCCC .75pt; padding: 3.45pt 3.45pt 3.45pt 3.45pt; width: 33.34%;" valign="top" width="33%"&gt;   &lt;div class="MsoNormal" style="line-height: 14.4pt; margin-bottom: .0001pt; margin-bottom: 0in;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10.0pt; mso-bidi-font-family: &amp;quot;Times New Roman&amp;quot;; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;"&gt;An   abstract class can have fields and constrants defined&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;div class="MsoNormal"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2010/01/interface-vs-abstract-class.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-1019178568631318152</guid><pubDate>Thu, 05 Nov 2009 06:03:00 +0000</pubDate><atom:updated>2009-11-04T22:03:47.167-08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Biztalk</category><title>BizTalk Architecture</title><description>&lt;span class="Apple-style-span" style="font-family: Verdana; font-size: 13px; line-height: 16px;"&gt;&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em;"&gt;Introduction&lt;/h2&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style="color: black; font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em;"&gt;I have heard they ask "How would you explain Excel (any product) to your grandmother?" in many companies; a question popularized by Microsoft, I believe. First, I am not so sure my grandma would understand any technology product so easily. Also, I am not sure if this is a good question to ask a software developer; maybe, to someone from sales, yes! On the record, I must say that my grandmother is an incredibly smart lady. So the question really boils down to "How you would make an IT common man understand what a product is all about?" This is what I am trying to endeavor in this article.&lt;br /&gt;
&lt;/div&gt;&lt;div style="color: black; font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em;"&gt;Sometime back, I had to explain to a group of non-IT folks about BizTalk Server. You know the people who wouldn't understand all these geeky terms like SOA, XML, SOAP, or Orchestrations (pardon me, she says she knows about SOAP!). I thought I'd share my experience here in this article for the benefit of the CodeProject community. This article is aimed at you if you have heard about this wonderful thing called BizTalk Server, and want to understand what it is clearly before diving into the marketing material which seems to be the same for every product - the "panacea" of all your problems.&lt;br /&gt;
&lt;/div&gt;&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em;"&gt;Drawing a Parallel&lt;/h2&gt;&lt;div style="color: black; font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em;"&gt;BizTalk Server is Microsoft's enterprise application integration solution, with built-in support for XML and SOAP. It offers integration with Visual Studio .NET, and provides speed, reliability, and flexibility for standards-based enterprise application integration. An analogy they say is&amp;nbsp;&lt;i&gt;"Similarity in some respects between things that are otherwise dissimilar"&lt;/i&gt;. So for me, to explain BizTalk, I would start off with an analogy. In the section below, I am comparing BizTalk Server to a Customs facility.&lt;br /&gt;
&lt;/div&gt;&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em;"&gt;The Customs Facility&lt;/h2&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSOw4ahyphenhyphenMr8VEHq8uK1eDqIzDRKs3exWEhrUPs7eMEskelS7wujPGmavPJX5kQKDF9j6R7B9YtVREuCXgBJkMYPoKaHLzwWPskMkMe1SMInOTCSaS5V_7bSfweWhPKx8cToNCUula381xg/s1600-h/001.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSOw4ahyphenhyphenMr8VEHq8uK1eDqIzDRKs3exWEhrUPs7eMEskelS7wujPGmavPJX5kQKDF9j6R7B9YtVREuCXgBJkMYPoKaHLzwWPskMkMe1SMInOTCSaS5V_7bSfweWhPKx8cToNCUula381xg/s320/001.JPG" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;span class="Apple-style-span" style="font-family: Verdana; font-size: 13px; line-height: 16px;"&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;What we have in the figure above is a Customs facility. We have an Import Terminal through which a large number of packages come in by different modes of transport: planes, ships, buses, trucks, barges. These packages then go through a standard inspection process, with several stages including identifying the package, unpacking the contents, and then identifying the shipper. The packages then go to a central store. From there, customs inspection of the packages takes place. The process could be different for different types of packages, and there is a "Customs Inspection Rules and Regulations Manual" which details the inspection process, and which in practice, gets updated from time to time. After a package passes the inspection process, it is sent back to the central store, from where it is packaged and sent to the correct destination.&lt;br /&gt;
&lt;/div&gt;&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;The BizTalk Server Architecture&lt;/h2&gt;&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;&lt;br /&gt;
&lt;/h2&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg3Fr5n2DCTwIFNlJRVE8nJSfgOqPawt_f_6YVLNXrbRNjPszDCtkXNsiSrJg7LtkshKmVK7F9hfC1JGV3z7YqFV66C8jxsi4VJm_IMIHVOY33_ouAz8Bhc-qLVwQHLmtXvoD0IGCeJeiz9/s1600-h/002.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg3Fr5n2DCTwIFNlJRVE8nJSfgOqPawt_f_6YVLNXrbRNjPszDCtkXNsiSrJg7LtkshKmVK7F9hfC1JGV3z7YqFV66C8jxsi4VJm_IMIHVOY33_ouAz8Bhc-qLVwQHLmtXvoD0IGCeJeiz9/s320/002.JPG" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;The figure above is the architecture of a BizTalk Server messaging subsystem. As you will notice, this figure is same as the previous figure except for the labeling. Here, instead of packages moving, we have XML messages that are moving. The files come in through Receive Ports and are passed to the "Message Box" through a "Receive Pipeline". They are then picked up by "BizTalk Orchestrations" and are processed. Custom rules maybe loaded and executed at this point. They are then send out using a Receive Pipeline through a "Send Port" to the destination.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Receive Ports&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;The Receive Ports are how messages come into BizTalk. Messages can come into BizTalk by any means of transport like HTTP, SOAP, SQL, file, EDI; just like the way packages arrive via planes, ships, buses, or trucks. How they are transported does not change how they are processed later. This is a very powerful feature because it gives you the ability to change the transport type and the source of the data even after your application is deployed, without changing your application implementation. For instance, let us say some sales related data is coming in from a shared "&lt;i&gt;FILE&lt;/i&gt;" folder in Europe connected via WAN today, tomorrow you can configure it as an FTP pickup from a remote server from India, or probably accept it as an HTTP request over the web posted from a browser.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Adaptors&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;Adaptors are the BizTalk way of handling additional transport. Just like you can have a private plane fly your package in, you can write your own adaptor for a custom transport, like say POP3. So there is always scope for buying or writing your own custom adaptor to integrate with all the other available transports. For instance, you can have a DB2 adaptor or a SAP adaptor.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Receive Pipeline&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;The Receive Pipeline contains different mechanisms like "Decoding" (if encoded), "Disassembling" (if there are multiple parts), and "Party Resolution". This is similar to the unpacking and identifying the sender, in our example. Just like we have an express lane for certain packages, there is a "Pass Through" pipeline facility in BizTalk which is essential a smooth transfer to the Message Box. Just like you can have special handling instructions for certain packages, you can write custom pipeline components using the framework.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Message Box and Subscriptions&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;The BizTalk Message Box lies in the heart of the BizTalk messaging subsystem; this is like our central store. This message box is, in fact, realized as a SQL Store; so this way, BizTalk ensures reliability for your messages in terms of guaranteed delivery. Even if a node in BizTalk fails, the message will be picked up by another node in the farm. BizTalk also ensures that it does not delete the file from a pickup folder location while using file/any transport, unless it is persisted completely in SQL. Well, this also means you need to have a fault tolerant SQL Server architecture. Just like we will be noting down a few important details while we unpack the packages, in the pipeline, certain properties are promoted into the context, like transport information: the most important of these being the incoming XMLSchema#RootNode. The BizTalk Publish-Subscribe mechanism identifies which Orchestrations subscribe to that particular message, based on this promoted information, and routes it accordingly.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Orchestrations&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;Orchestrations are processes that are defined in the Business Process Execution Language (BPEL). This could be something like, say: if quantity is greater than threshold, apply discount, else standard discount. At this stage, you can also change the format of the message using Transformation Maps, or you can call some other web service to do an operation like credit card verification. This is like our example in which we have the customs inspection process and checking with the bank if the excise payment is cleared.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Business Rules Engine&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;Business Rules Engine is used by BizTalk to load the current policies which are a collection of Rules from the Orchestration. These rules are kept separately as these could change from time to time. In our example above, this would be something like, during Olympics there could be certain relaxations in guidelines or certain promotions in effect. These change from time to time, and they are kept separate. This is the idea behind the Rule Store in BizTalk.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Send Pipeline&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;The "Send Pipelines" are just the opposite of the "Receive Pipelines" and they do operations like "Encoding" the message, or "Assembling" or "Signing" the message. This is like packing and sealing a package before we send it. Just like we have different types of packaging like bubble wrapping and cushion mailers, there could be different pipeline components at this stage.&lt;br /&gt;
&lt;/div&gt;&lt;h3 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 11pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;Send Ports&lt;/h3&gt;&lt;div style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 10pt; line-height: 1.2em; text-align: left;"&gt;Send Ports also handle transport like receive ports, but their direction is the reverse. Here, the message direction is from the Message Box to the destination. Send Ports can subscribe to a message directly from the Message Box, without passing through the orchestration. This is like having a package coming in from a certain shipper which has a prior clearance attached with it. This is called Content Based Routing (CBR).&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em; text-align: left;"&gt;&lt;br /&gt;
&lt;/h2&gt;&lt;br /&gt;
&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em;"&gt;&lt;br /&gt;
&lt;/h2&gt;&lt;h2 style="font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em;"&gt;&lt;br /&gt;
&lt;/h2&gt;&lt;h2 style="color: #ff9900; font-family: Verdana, Helvetica, Arial, sans-serif; font-size: 13pt; font-weight: bold; line-height: 1.2em;"&gt;&lt;br /&gt;
&lt;/h2&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/11/biztalk-architecture.html</link><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" height="72" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSOw4ahyphenhyphenMr8VEHq8uK1eDqIzDRKs3exWEhrUPs7eMEskelS7wujPGmavPJX5kQKDF9j6R7B9YtVREuCXgBJkMYPoKaHLzwWPskMkMe1SMInOTCSaS5V_7bSfweWhPKx8cToNCUula381xg/s72-c/001.JPG" width="72"/><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-413189577007341539</guid><pubDate>Sat, 31 Oct 2009 06:41:00 +0000</pubDate><atom:updated>2009-10-30T23:41:48.651-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Sharepoint</category><title>Sharepoint Tools</title><description>I have tried to summarise the list of development tools that you require on your day to day development. Please post your comment, if I miss anything here.&lt;br /&gt;
&lt;br /&gt;
    * App Pool Manager (http://www.harbar.net/apm/apm2.zip)&lt;br /&gt;
    * U2U CAML Query Builder (http://www.u2u.info/SharePoint/U2U%20Community%20Tools/U2U%20Caml%20Query%20Builder%202007%20v3.1.0.0%20(windows%20version).zip)&lt;br /&gt;
    * .NET Reflector (http://reflector.red-gate.com/download.aspx)&lt;br /&gt;
    * SharePoint Explorer for WSS 3.0 ( )&lt;br /&gt;
    * SharePoint Log Reader (http://www.blogaboutsharepoint.com/wp-content/plugins/download-monitor/download.php?id=1)&lt;br /&gt;
    * BDC Meta Man Tool (http://www.lightningtools.com/pages/service/customerdownloads.aspx)&lt;br /&gt;
    * SharePoint Inspector 1.0.0.0 (http://spi.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=1652#DownloadId=5854)&lt;br /&gt;
    * SharePoint Explorer for WSS 3.0 (http://download.mondosoft.com/Ontolica/SharePointExplorer_V1_5_1_For_WSS3.zip)&lt;br /&gt;
    * SharePoint Dispose Checker Tool (http://download.microsoft.com/download/B/4/D/B4D279A0-E159-40BF-A5E8-F49ABDBE95C7/SPDisposeCheck.msi)&lt;br /&gt;
    * Windows SharePoint Services 3.0 SDK (http://www.microsoft.com/downloads/details.aspx?familyid=05E0DD12-8394-402B-8936-A07FE8AFAFFD&amp;displaylang=en)&lt;br /&gt;
    * Microsoft Office SharePoint Server 2007 SDK (http://www.microsoft.com/downloads/details.aspx?familyid=6D94E307-67D9-41AC-B2D6-0074D6286FA9&amp;displaylang=en)&lt;br /&gt;
    * Microsoft InfoPath 2007&lt;br /&gt;
    * Microsoft SharePoint Designer 2007&lt;br /&gt;
    * Microsoft Office 2007&lt;br /&gt;
    * WSP Builder for SharePoint (http://www.codeplex.com/wspbuilder)&lt;br /&gt;
    * Windows SharePoint Services 3.0 Tools: Visual Studio 2005 Extensions (http://www.microsoft.com/downloads/details.aspx?FamilyID=3e1dcccd-1cca-433a-bb4d-97b96bf7ab63&amp;DisplayLang=en)&lt;br /&gt;
    * Windows SharePoint Services 3.0 Tools: Visual Studio 2008 Extensions (http://www.microsoft.com/downloads/details.aspx?familyid=7BF65B28-06E2-4E87-9BAD-086E32185E68&amp;displaylang=en)&lt;br /&gt;
    * SharePoint Administration Toolkit v2.0&lt;br /&gt;
      x64: http://www.microsoft.com/downloads/details.aspx?FamilyId=F8EEA8F0-FA30-4C10-ABC9-217EEACEC9CE&amp;displaylang=en&lt;br /&gt;
      x86: http://www.microsoft.com/downloads/details.aspx?FamilyId=263CD480-F6EB-4FA3-9F2E-2D47618505F2&amp;displaylang=en&lt;br /&gt;
    * SmartPart (http://www.codeplex.com/smartpart)&lt;br /&gt;
    * SharePoint Installer (http://www.codeplex.com/sharepointinstaller)&lt;br /&gt;
    * SOAP calls to the SharePoint web services (http://www.soapui.org/)&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/10/sharepoint-tools.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-5702002580846414944</guid><pubDate>Sun, 25 Oct 2009 05:37:00 +0000</pubDate><atom:updated>2009-10-24T22:38:43.463-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Architecture</category><title>Classes Vs Modules</title><description>&lt;div align="left" style="font-family: inherit;" valign="bottom"&gt;&lt;span style="font-size: small;"&gt;Both classes and modules are reference types that encapsulate items defined within, but they differ in how these items are accessed from other procedures.&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div align="left" style="font-family: inherit;" valign="bottom"&gt;&lt;span style="font-size: small;"&gt;The primary difference between classes and modules is that classes can be instantiated and standard modules cannot. Because there is never more than one copy of a standard module's data, when one part of your program changes a public variable in a standard module, any other part of the program gets the same value if it subsequently reads that variable. Class data, on the other hand, exists separately for each instantiated object. Another difference is that unlike standard modules, classes can implement interfaces.&lt;/span&gt; &lt;br /&gt;
&lt;/div&gt;&lt;div align="left" style="font-family: inherit;" valign="bottom"&gt;&lt;span style="font-size: small;"&gt;Classes and modules also employ different scope for their members. Members defined within a class are scoped within a specific instance of the class, and exist only for the lifetime of the object. The practical result is that, to access class members from outside a class, you must use only fully qualified names; for example, &lt;/span&gt;&lt;span style="font-size: small;"&gt;&lt;code class="ce"&gt;Object.Member&lt;/code&gt;&lt;/span&gt;&lt;span style="font-size: small;"&gt;. Members declared within a standard module, on the other hand, are shared by default, and are scoped to the declaration space of the standard module's containing namespace. This means that public variables in a standard module are effectively global variables because they are visible from anywhere in your project, and they exist for the life of the program. Unlike class members, members of standard modules are implicitly shared and cannot use the &lt;a href="http://msdn.microsoft.com/en-us/library/zc2b427x%28VS.71%29.aspx" id="ctl00_MTCS_main_ctl01" onclick="javascript:Track('ctl00_MTCS_main_ctl00|ctl00_MTCS_main_ctl01',this);"&gt;Shared&lt;/a&gt; keyword.&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/10/classes-vs-modules.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-2812261334247751625</guid><pubDate>Wed, 21 Oct 2009 05:17:00 +0000</pubDate><atom:updated>2009-10-20T22:21:56.432-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Architecture</category><title>Difference between Physical Architecture and Logical Architecture</title><description>&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;When most people talk about n-tier applications, they’re talking about physical models in which&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;the application is spread across multiple machines with different functions: a client, a web server, an&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;application server, a database server, and so on. And this isn’t a misconception—these are indeed&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;n-tier systems. The problem is that many people tend to assume there’s a one-to-one relationship&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;between the layers (tiers) in a logical model and the tiers in a physical model, when in fact that’s not&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;always true.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;A &lt;/span&gt;&lt;i&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;physical &lt;/span&gt;&lt;/i&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;n-tier architecture is quite different from a &lt;/span&gt;&lt;i&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;logical &lt;/span&gt;&lt;/i&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;n-layer architecture. An n-layer&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;architecture has nothing to do with the number of machines or network hops involved in running&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;the application. Rather, a logical architecture is all about separating different types of functionality.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;The most common logical separation is into an Interface layer, a Business layer, and a Data layer.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;These may exist on a single machine or on three separate machines—the logical architecture doesn’t&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="line-height: normal; margin-bottom: .0001pt; margin-bottom: 0in; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;span style="font-family: Verdana, sans-serif; font-size: 9pt;"&gt;define those details.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/10/difference-between-physical.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-4293618665658366215</guid><pubDate>Tue, 20 Oct 2009 05:38:00 +0000</pubDate><atom:updated>2009-10-19T22:38:24.113-07:00</atom:updated><title>Use Client-Side JavaScript to Disable ASP.NET Validators</title><description>&lt;span class="Apple-style-span" style="color: #333333; font-family: Verdana; font-size: 11px; line-height: 16px;"&gt;&lt;/span&gt;&lt;br /&gt;
&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;This came up this week on a project I am working on and now it will transcend to other projects.&amp;nbsp; I needed to rewrite some functionality utilizing client-side code.&amp;nbsp; Well, I could've done it server-side but I'm not&amp;nbsp;a fan of unnecessary postbacks (or&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;UpdatePanel&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;"partial postbacks") so I decided to utilize JavaScript.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;So I removed all the&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;AutoPostBack="true"&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;'s from the codebase and utilized my favorite property (&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Control.ClientID&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;) to set the css display style to "none" or "" depending on which option was selected.&amp;nbsp; After all that was done I decided to test. Uh-oh, my&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;RequiredFieldValidators&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&amp;nbsp;were firing off since I was only using CSS* to hide / unhide my&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Panels&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;. Instead of adding values to these controls to satisfy the expressions (which doesn't work all of the time (i.e.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;input type='file'&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&amp;nbsp;or&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;asp:FileUpload&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&amp;nbsp;which don't allow the setting of a posted file as it is a security risk). I found out how to turn off validation.&amp;nbsp; It only took a little bit to add via codebehind.cs.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;For this example, I have a&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;CheckBox&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&amp;nbsp;for&amp;nbsp;checks that when clicked needs to disable a&lt;/span&gt;&lt;/span&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;RequiredFieldValidator&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&amp;nbsp;for CreditCard.&amp;nbsp; Stupid example I know.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;/code&gt;&lt;/span&gt;&lt;/span&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;check.Attributes.Add(&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #a31515; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;"onclick"&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;,&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;string&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;.Format(&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #a31515; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;"disable('{0}')"&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;, regexCreditCard.ClientID));&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;That will add the appropriate handler for client-side work. Now that that is out of the way, time for the actual disabling of the validator.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;code style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: #fafafa; background-image: initial; background-position: initial initial; background-repeat: initial; border-bottom-color: rgb(242, 242, 242); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(242, 242, 242); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(242, 242, 242); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(242, 242, 242); border-top-style: solid; border-top-width: 1px; font: normal normal 500 1em/1.5em 'Courier New', 'Lucida Console', 'courier new', monospace; margin-bottom: 5px; margin-left: 0px; margin-right: 0px; margin-top: 5px; overflow-x: auto; overflow-y: auto; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-align: left;"&gt;&lt;span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;function&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&amp;nbsp;disable(validatorId)&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;{&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;var&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&amp;nbsp;validator = document.getElementById(validatorId);&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;ValidatorEnable(validator,&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: blue; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;false&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;);&lt;br style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;}&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Easy. Now you can use .NET to implement tamper-proof validation and disable / enable via JavaScript for a richer user experience.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 10px; padding-right: 10px; padding-top: 10px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;* Using "display: none" is much better than simply using "visibility: hidden" for what's it's worth (at least it was for me).&amp;nbsp; With "visibility: hidden" you can tell that something is&lt;/span&gt;&lt;/span&gt;&lt;em style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;supposed&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/em&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;to be there. With "display: none" you can't.&amp;nbsp; So in summary, "visibility: hidden" results in the page calculating this div as part of the flow.&amp;nbsp; With "display: none", it's not even accounted for.&amp;nbsp; It's as if it were never there!&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/10/use-client-side-javascript-to-disable.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-5597241158073436243</guid><pubDate>Sun, 18 Oct 2009 05:06:00 +0000</pubDate><atom:updated>2009-10-17T22:27:00.351-07:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">.Net Articles</category><title>Microsoft's Live Framework</title><description>Microsoft is now positioning the Live Framework as the development framework for all of Microsoft’s Live services, not just Live Mesh. The Live Framework is akin to the .Net Framework, but is aimed to support developers writing mostly consumer-focused applications and services that need online/offline synchronization and work across the PC, Web and devices.&lt;br /&gt;
&lt;br /&gt;
Here at Microsoft Professional Developer Conference (PDC), Microsoft announced that its Live Framework is now “live,” as in Microsoft allowing developers to sign up to test drive it.&lt;br /&gt;
&lt;br /&gt;
Microsoft also made some tweaks to the framework since it first unveiled plans for it. Some of the names of the different subsystems within the framework are different. And the way that Live Mesh and Silver light work together has been fleshed out. The Framework now includes support for contacts, so that developers can build applications that will be designed to spread vi-rally.&lt;br /&gt;
&lt;br /&gt;
We’re unleashing (contacts) in the platform. We’re making social-graph information available to developers to help them make their applications viral,” said Jeff Hansen, General Manager Services Marketing.&lt;br /&gt;
&lt;br /&gt;
&lt;div style="text-align: center;"&gt;Here’s what the Live Framework looked like in April:&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg8Rts7xlxbOcMhXcNS7q6i6BgkCx9pT103bR1fLzz44dMNG0FRj54Qp2VscxEtp8kCXCCogWIWPPoNbAsPJd6avjAMQ7ZWUccsqPNEQS5SRucSs1vj9WMXBVJSdGY59iBM8NeQCVpnXYGz/s1600-h/1.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg8Rts7xlxbOcMhXcNS7q6i6BgkCx9pT103bR1fLzz44dMNG0FRj54Qp2VscxEtp8kCXCCogWIWPPoNbAsPJd6avjAMQ7ZWUccsqPNEQS5SRucSs1vj9WMXBVJSdGY59iBM8NeQCVpnXYGz/s320/1.JPG" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;And here’s what the Live Framework looks like now:&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgugw7zsNdNnc3ZMUX3DKdbGhkkQWIr2pl-bqLuTqw93JZubH_4eqmfKQVj_IeQDkTYLa0c_6o6Xlu5RYy_ylIKCCT0mWom0QfODi3nrT3gdoQhmwsaCGZ3ZQ-l1PH5ocYgO_MUv8kqEiXf/s1600-h/2.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgugw7zsNdNnc3ZMUX3DKdbGhkkQWIr2pl-bqLuTqw93JZubH_4eqmfKQVj_IeQDkTYLa0c_6o6Xlu5RYy_ylIKCCT0mWom0QfODi3nrT3gdoQhmwsaCGZ3ZQ-l1PH5ocYgO_MUv8kqEiXf/s320/2.JPG" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: left;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="separator" style="clear: both; text-align: left;"&gt;The infrastructure services layer, even though it’s not visible in the newly revised slide, remains the same: It’s Windows Azure (Red Dog) and the building-block Azure services. The Mesh FX (framework) is now simply called the “programming model.” The Mesh operating environment&amp;nbsp; is now the Live Operating Environment. The operating environment consists of three pillars: Data, applications and communications.&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
“We want to make it easy for rich applications to extend to the cloud. But we also want to help Web apps break free of the browser frame and go offline,” explained Abhay Parasnis, General Manager of Live Mesh. “We also want to enable developers of applications inject social-graph data into their applications.”&lt;br /&gt;
&lt;br /&gt;
Developers are going to be able to wrap a Silver-light application with an “invisible” Internet Explorer wrapper and publish an application to Mesh. Through the Mesh synchronization model, developers can enable their applications to run locally on any Mesh-enabled system or device. When users reconnect and go online, these local Silverlight apps will automatically synchronize.&lt;br /&gt;
&lt;br /&gt;
So what’s next for Mesh? Microsoft will be moving more of its Live services onto the base Red Dog cloud operating system, officials said. Right now, Live Mesh is the first of those services that is (partially) hosted in Microsoft’s cloud. Microsoft also will continue to extend its base Live Services platform. Right now, that platform consists of shared identity; directory; communication and presence; search and geospatial; and contacts. Expect Live Workspace, groups, calendars and other core elements to be added to the platform in the coming months. &lt;br /&gt;
&lt;div style="text-align: center;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/10/microsofts-live-framework.html</link><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" height="72" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg8Rts7xlxbOcMhXcNS7q6i6BgkCx9pT103bR1fLzz44dMNG0FRj54Qp2VscxEtp8kCXCCogWIWPPoNbAsPJd6avjAMQ7ZWUccsqPNEQS5SRucSs1vj9WMXBVJSdGY59iBM8NeQCVpnXYGz/s72-c/1.JPG" width="72"/><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-6875079448650128466</guid><pubDate>Sun, 18 Oct 2009 05:00:00 +0000</pubDate><atom:updated>2009-10-17T22:00:09.915-07:00</atom:updated><title>Microsoft vs Google</title><description>&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: Verdana,sans-serif;"&gt;Regardless of whether you’re in the Google camp or in the Microsoft camp, I think it’s a fair statement to say that these differences of viewpoint accurately reflect each company’s core strength and focus: Google wants the browser to grow to subsume the desktop; Microsoft wants the desktop to grow to subsume the cloud.&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/10/microsoft-vs-google.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-5370603996497030806</guid><pubDate>Mon, 28 Sep 2009 10:41:00 +0000</pubDate><atom:updated>2009-09-28T05:42:30.089-07:00</atom:updated><title>Google Wave A New Kind of Mega-Application</title><description>&lt;blockquote&gt;Google's newly unveiled Wave may be called a communication and collaboration tool, but it's much more than that. Wave combines key Web trends from the last couple of years into one elegant application. And it may make today's enterprise tools such as Microsoft SharePoint look ridiculously complicated. &lt;/blockquote&gt;&lt;br /&gt;
Read Further : &lt;a href="http://www.cio.com/article/493707/Google_Wave_A_New_Kind_of_Mega_Application"&gt; Google Wave Application  &lt;/a&gt;&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/09/google-wave-new-kind-of-mega.html</link><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-6921611210899688855.post-7012558536181127630</guid><pubDate>Fri, 25 Sep 2009 15:19:00 +0000</pubDate><atom:updated>2009-09-25T08:55:42.376-07:00</atom:updated><title>Dark Side Of  UpdatePanel</title><description>&lt;div style="text-align: justify;"&gt;&lt;meta content="text/html; charset=utf-8" http-equiv="Content-Type"&gt;&lt;/meta&gt;&lt;meta content="Word.Document" name="ProgId"&gt;&lt;/meta&gt;&lt;meta content="Microsoft Word 12" name="Generator"&gt;&lt;/meta&gt;&lt;meta content="Microsoft Word 12" name="Originator"&gt;&lt;/meta&gt;&lt;link href="file:///C:%5CDOCUME%7E1%5CABDULK%7E1%5CLOCALS%7E1%5CTemp%5Cmsohtmlclip1%5C03%5Cclip_filelist.xml" rel="File-List"&gt;&lt;/link&gt;&lt;link href="file:///C:%5CDOCUME%7E1%5CABDULK%7E1%5CLOCALS%7E1%5CTemp%5Cmsohtmlclip1%5C03%5Cclip_editdata.mso" rel="Edit-Time-Data"&gt;&lt;/link&gt;&lt;link href="file:///C:%5CDOCUME%7E1%5CABDULK%7E1%5CLOCALS%7E1%5CTemp%5Cmsohtmlclip1%5C03%5Cclip_themedata.thmx" rel="themeData"&gt;&lt;/link&gt;&lt;link href="file:///C:%5CDOCUME%7E1%5CABDULK%7E1%5CLOCALS%7E1%5CTemp%5Cmsohtmlclip1%5C03%5Cclip_colorschememapping.xml" rel="colorSchemeMapping"&gt;&lt;/link&gt;    &lt;m:smallfrac m:val="off"&gt;    &lt;m:dispdef&gt;    &lt;m:lmargin m:val="0"&gt;    &lt;m:rmargin m:val="0"&gt;    &lt;m:defjc m:val="centerGroup"&gt;    &lt;m:wrapindent m:val="1440"&gt;    &lt;m:intlim m:val="subSup"&gt;    &lt;m:narylim m:val="undOvr"&gt;   &lt;/m:narylim&gt;&lt;/m:intlim&gt; &lt;/m:wrapindent&gt;&lt;style&gt;
&lt;!--
 /* Font Definitions */
 @font-face
	{font-family:"Cambria Math";
	panose-1:2 4 5 3 5 4 6 3 2 4;
	mso-font-charset:0;
	mso-generic-font-family:roman;
	mso-font-pitch:variable;
	mso-font-signature:-1610611985 1107304683 0 0 159 0;}
@font-face
	{font-family:Verdana;
	panose-1:2 11 6 4 3 5 4 4 2 4;
	mso-font-charset:0;
	mso-generic-font-family:swiss;
	mso-font-pitch:variable;
	mso-font-signature:536871559 0 0 0 415 0;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{mso-style-unhide:no;
	mso-style-qformat:yes;
	mso-style-parent:"";
	margin:0in;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:12.0pt;
	font-family:"Times New Roman","serif";
	mso-fareast-font-family:"Times New Roman";}
p
	{mso-style-priority:99;
	mso-margin-top-alt:auto;
	margin-right:0in;
	mso-margin-bottom-alt:auto;
	margin-left:0in;
	mso-pagination:widow-orphan;
	font-size:12.0pt;
	font-family:"Times New Roman","serif";
	mso-fareast-font-family:"Times New Roman";}
span.ilspan
	{mso-style-name:il_span;
	mso-style-unhide:no;}
.MsoChpDefault
	{mso-style-type:export-only;
	mso-default-props:yes;
	font-size:10.0pt;
	mso-ansi-font-size:10.0pt;
	mso-bidi-font-size:10.0pt;}
@page Section1
	{size:8.5in 11.0in;
	margin:1.0in 1.0in 1.0in 1.0in;
	mso-header-margin:.5in;
	mso-footer-margin:.5in;
	mso-paper-source:0;}
div.Section1
	{page:Section1;}
--&gt;
&lt;/style&gt;  &lt;/m:defjc&gt;&lt;/m:rmargin&gt;&lt;/m:lmargin&gt;&lt;/m:dispdef&gt;&lt;/m:smallfrac&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class="MsoNormal" style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt;"&gt;The UpdatePanel function ASP.Net for Ajax provides the robust support for easy web &lt;span style="display: none;"&gt;&lt;input name="IL_MARKER" type="hidden" /&gt;&lt;/span&gt;navigation &lt;span style="display: none;"&gt;&lt;input name="IL_MARKER" type="hidden" /&gt;&lt;/span&gt;tool. Ajax is a great thing when it comes to interaction and user experience but you will be overdoing &lt;span style="display: none;"&gt;&lt;input name="IL_MARKER" type="hidden" /&gt;&lt;/span&gt;your website when you place everything in the UpdatePanel.&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt;"&gt;UpdatePanel is a great &lt;span style="display: none;"&gt;&lt;input name="IL_MARKER" type="hidden" /&gt;&lt;/span&gt;tool for an Ajax based development but it does not mean you have to use it whenever you have the chance. A simple HTML or the simplified version of Ajax will prove useful while maintaining simplicity and efficiency.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt;"&gt;Placing the web content in the UpdatePanel will mean every time information is requested, the UpdatePanel will get in touch with the XMLHttpRequest which in turns builds an HTTP Post. After that the ASP.Net builds the page class using the ViewState that we created in the HTTP POST. After ViewState a parser is made for the specific part of the webpage which will also run through the lifecycle. After it parses, the DOM is eventually updated displaying the webpage.&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt;"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span style="font-family: &amp;quot;Verdana&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt;"&gt;The Problem recently I face while working with updatepanel in the ASP.net page is&amp;nbsp; that, it is not going to postback at all while performing an event on the page. After digging out i come to know, is due to, I put a onsubmit ( JavaScript ) script on the Form (Server Side)tag and it stops the partial page postback. After removing that script element ( onsubmit='javascript') from Form tag, Page Post back is ok. A snippet is attached to view. &amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjP57_ghwFZSZqoLZsVkDLragxAAaYmdIodAEozoKVNjndBDpbF6NQjk9gr62lG_q5BSLCHXI2MHrGruXVe8G4L8eztFB2yVsqYmClOSKB54zmZAHL59yCHwUrWhN64G1_dvuPKQG_Wr8EO/s1600-h/snippet01.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjP57_ghwFZSZqoLZsVkDLragxAAaYmdIodAEozoKVNjndBDpbF6NQjk9gr62lG_q5BSLCHXI2MHrGruXVe8G4L8eztFB2yVsqYmClOSKB54zmZAHL59yCHwUrWhN64G1_dvuPKQG_Wr8EO/s320/snippet01.JPG" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
&lt;div class="blogger-post-footer"&gt;eTechMentor&lt;/div&gt;</description><link>http://etechmentors.blogspot.com/2009/09/dark-side-of-updatepanel.html</link><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" height="72" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjP57_ghwFZSZqoLZsVkDLragxAAaYmdIodAEozoKVNjndBDpbF6NQjk9gr62lG_q5BSLCHXI2MHrGruXVe8G4L8eztFB2yVsqYmClOSKB54zmZAHL59yCHwUrWhN64G1_dvuPKQG_Wr8EO/s72-c/snippet01.JPG" width="72"/><thr:total>0</thr:total><author>etechmentor@gmail.com (Adul Malik)</author></item></channel></rss>