<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-2377727724851115192</atom:id><lastBuildDate>Fri, 27 Jan 2012 03:59:49 +0000</lastBuildDate><category>Denali</category><category>Performance</category><category>FAQ</category><category>SQL Server Agent</category><category>Download</category><category>si-lk</category><category>Review</category><category>Replication</category><category>Auditing</category><category>SQL Server 2012</category><category>CTP</category><category>Encryption</category><category>Security</category><category>Azure</category><category>Instalation</category><category>Administration</category><category>MongoDB</category><category>Analysis Services</category><category>Excell</category><category>SQL Server Performance</category><category>Feature Request</category><category>Clustering</category><category>Data warehouse</category><category>Law</category><category>SSIS</category><category>Articles</category><category>Video</category><category>Community Launch</category><category>News</category><category>Service Packs</category><category>Integration Services</category><category>Licensing</category><category>Servey</category><category>mySQL</category><category>SQL Server 2008</category><category>Certification</category><category>Data Mining</category><category>Log Shipping</category><category>Fun</category><category>Reporting Services</category><category>NoSQL</category><category>BeyondRelational</category><category>Link Server</category><category>Editions</category><category>Development</category><category>Bugs</category><category>BI</category><category>Tools</category><category>SQL Server 2008 R2</category><category>Speaking Engagement</category><category>Extended Events</category><category>Books</category><title>a true friend on database matters</title><description /><link>http://dbfriend.blogspot.com/</link><managingEditor>noreply@blogger.com (Dinesh Asanka)</managingEditor><generator>Blogger</generator><openSearch:totalResults>182</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/blogspot/npKe" /><feedburner:info xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" uri="blogspot/npke" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-879811644299084167</guid><pubDate>Fri, 27 Jan 2012 03:52:00 +0000</pubDate><atom:updated>2012-01-27T09:29:49.369+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Administration</category><title>Concurrent Administration Tasks?</title><description>&lt;p&gt;Can you run a full database backup and a file shrink at the same time? &lt;/p&gt; &lt;p&gt;Can you run a full database backup and a filegroup backup at the same time?&lt;/p&gt; &lt;p&gt;Answer to both of the questions are NO.&lt;/p&gt; &lt;p&gt;Can you run run full back and log backup at the same time?&lt;/p&gt; &lt;p&gt;Answer is Yes &lt;img style="border-bottom-style: none; border-left-style: none; border-top-style: none; border-right-style: none" class="wlEmoticon wlEmoticon-smilewithtongueout" alt="Smile with tongue out" src="http://lh5.ggpht.com/-2WNWiIiyz_c/TyIfjCZ68CI/AAAAAAAAAbQ/vVGu0SXW_MM/wlEmoticon-smilewithtongueout%25255B2%25255D.png?imgmax=800"&gt;&lt;/p&gt; &lt;p&gt;How to you know these? What can be done with what? Here is the chart which tells you about it?&lt;/p&gt; &lt;p&gt;This image will tell you the story.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-qAvCzLLN4B8/TyIfjvB1MVI/AAAAAAAAAbY/solWpZWyFWo/s1600-h/clip_image001%25255B5%25255D.gif"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="clip_image001" border="0" alt="clip_image001" src="http://lh3.ggpht.com/-cgjmYhTbc9Q/TyIfkt_G40I/AAAAAAAAAbg/T3VRBWXjNVc/clip_image001_thumb%25255B2%25255D.gif?imgmax=800" width="460" height="475"&gt;&lt;/a&gt; &lt;p&gt;Source: MSDN &lt;p&gt;Not all administrative tasks are allowed to run concurrently. In the table above, a &lt;b&gt;black circle indicates two operations that cannot run in a database&lt;/b&gt; at the same time.   &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-879811644299084167?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/concurrent-administration-tasks.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh5.ggpht.com/-2WNWiIiyz_c/TyIfjCZ68CI/AAAAAAAAAbQ/vVGu0SXW_MM/s72-c/wlEmoticon-smilewithtongueout%25255B2%25255D.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-2340569530836108579</guid><pubDate>Tue, 24 Jan 2012 04:22:00 +0000</pubDate><atom:updated>2012-01-24T09:52:11.241+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">SQL Server 2012</category><title>Microsoft's SQL Server 2012 to launch on March 7</title><description>&lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;The launch date for SQL Server 2012 is out of the bag: It’s March 7.&lt;br&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;&lt;a href="http://i.zdnet.com/blogs/sqlserver2012launch.png"&gt;&lt;img title="sqlserver2012launch" alt="" src="http://i.zdnet.com/blogs/sqlserver2012launch.png" width="475" height="165"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Read more at &lt;a title="http://www.zdnet.com/blog/microsoft/microsofts-sql-server-2012-to-launch-on-march-7/11718" href="http://www.zdnet.com/blog/microsoft/microsofts-sql-server-2012-to-launch-on-march-7/11718"&gt;http://www.zdnet.com/blog/microsoft/microsofts-sql-server-2012-to-launch-on-march-7/11718&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-2340569530836108579?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/microsoft-sql-server-2012-to-launch-on.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-5139170006018515193</guid><pubDate>Mon, 23 Jan 2012 18:27:00 +0000</pubDate><atom:updated>2012-01-23T23:57:55.515+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Development</category><title>Why not to use NOT IN?</title><description>&lt;p&gt;NOT IN is handy syntax use. However, is it a syntax you can always use? Just see the following examples.&lt;/p&gt; &lt;p&gt;Let use say we have two tables named &lt;strong&gt;First&lt;/strong&gt; and &lt;strong&gt;Second&lt;/strong&gt; and data contains as follows.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-qecbtPV735U/Tx2mfFXu0hI/AAAAAAAAAaQ/hSpfk2WUmxg/image%25255B7%25255D.png?imgmax=800"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-4zwlNWqPZQg/Tx2mhH2TQvI/AAAAAAAAAaY/DnpYSHY6TtQ/image_thumb%25255B3%25255D.png?imgmax=800" width="218" height="365"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Let’s say you execute following statement. &lt;/p&gt;   &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-nzOjBEd-ZYQ/Tx2miQq5K3I/AAAAAAAAAag/QmvRdXGGwA4/image%25255B11%25255D.png?imgmax=800"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-QFiwprrojns/Tx2mjuwzWUI/AAAAAAAAAao/ETDnLIDcKL0/image_thumb%25255B5%25255D.png?imgmax=800" width="337" height="64"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;What do you think about about. You might think that you should get 2 – Oracle as the result. If so, you are WRONG!!!&lt;/p&gt; &lt;p&gt;Above query will result NOTHING!!! Yes nothing.&lt;/p&gt; &lt;p&gt;Let us try to replace NOT IN with NOT EXISTS and compare the results.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-STPbitv48pQ/Tx2mlOGHE5I/AAAAAAAAAaw/vSM4Em3uPfo/image%25255B16%25255D.png?imgmax=800"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-63hdgEZKDjw/Tx2mm8gyMcI/AAAAAAAAAa4/w9B63pcWfcY/image_thumb%25255B8%25255D.png?imgmax=800" width="383" height="230"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Well, NOT EXISTS returned the desired results.&lt;/p&gt; &lt;p&gt;Let us interchange the tables. &lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-agZS0GSaWCQ/Tx2mohh3HFI/AAAAAAAAAbA/xDmIhz58ZZA/image%25255B21%25255D.png?imgmax=800"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-k0Khz_eJ6Ew/Tx2mqF6ykEI/AAAAAAAAAbI/3eBc9z3BQrQ/image_thumb%25255B11%25255D.png?imgmax=800" width="344" height="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Again NOT IN not giving us the correct results. Point to note here is, NULL values not working very well with NOT IN. So make sure you are not dealing with NULL values when using NOT IN.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-5139170006018515193?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/why-not-to-use-not-in.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh5.ggpht.com/-4zwlNWqPZQg/Tx2mhH2TQvI/AAAAAAAAAaY/DnpYSHY6TtQ/s72-c/image_thumb%25255B3%25255D.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-3889811666520387358</guid><pubDate>Sun, 22 Jan 2012 01:50:00 +0000</pubDate><atom:updated>2012-01-22T07:20:16.962+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">Integration Services</category><title>New SSIS Functions in Denali</title><description>&lt;p&gt; Four New functions are included in Denali for SSIS.&lt;/p&gt; &lt;p&gt; &lt;table border="0" cellspacing="0" cellpadding="2" width="420"&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td valign="top" width="98"&gt;&lt;strong&gt;Function&lt;/strong&gt;&lt;/td&gt; &lt;td valign="top" width="260"&gt;&lt;strong&gt;Example&lt;/strong&gt;&lt;/td&gt; &lt;td valign="top" width="60"&gt;&lt;strong&gt;Output&lt;/strong&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="98"&gt;LEFT&lt;/td&gt; &lt;td valign="top" width="260"&gt;LEFT(“Denali,3)&lt;/td&gt; &lt;td valign="top" width="60"&gt;Den&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="98"&gt;TOKEN&lt;/td&gt; &lt;td valign="top" width="260"&gt;TOKEN(“SQL Server 2012”,” “ ,2)&lt;/td&gt; &lt;td valign="top" width="60"&gt;Server&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="98"&gt;TOKENCOUNT&lt;/td&gt; &lt;td valign="top" width="260"&gt;TOKENCOUNT(“SQL Server 2012”,” “ )&lt;/td&gt; &lt;td valign="top" width="60"&gt;3&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="98"&gt; &lt;p&gt;REPLACENULL&lt;/p&gt;&lt;/td&gt; &lt;td valign="top" width="260"&gt; &lt;p&gt;REPLACENULL(NULL,2)&lt;/p&gt;&lt;/td&gt; &lt;td valign="top" width="60"&gt;2&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-3889811666520387358?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/new-ssis-functions-in-denali.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-1954863550041674498</guid><pubDate>Tue, 17 Jan 2012 02:52:00 +0000</pubDate><atom:updated>2012-01-17T08:22:17.531+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Speaking Engagement</category><title>[SS SLUG] January 2012 Meetup</title><description>&lt;p&gt;&lt;a href="http://www.sqlserveruniverse.com/v2/Home.aspx"&gt;&lt;img border="0" src="http://www.sqlserveruniverse.com/v2/Portals/0/SQLServerUniverse_Banner.png" width="513" height="73"&gt;&lt;/a&gt; &lt;table border="0" cellpadding="0"&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;Announcing the January 2012 meet-up of the SQL Server Sri Lanka User Group (SS SLUG). &lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td&gt; &lt;hr align="center" size="2" width="100%"&gt; &lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top" width="370"&gt; &lt;p&gt;Session #1 &lt;p&gt;&lt;strong&gt;Using Resource Governor to Manage workload and resources&lt;/strong&gt; by &lt;em&gt;Dinesh Asanka (MVP)&lt;/em&gt; &lt;p&gt;Resource Governor is a new technology in SQL Server 2008 that enables you to manage SQL Server workload and resources by specifying limits on resource consumption by incoming requests. Join this session to see how you can take advantage of this cool piece of technology. &lt;p&gt;&lt;u&gt;Dinesh blogs at&lt;/u&gt;: &lt;a href="http://dbfriend.blogspot.com/"&gt;http://dbfriend.blogspot.com/&lt;/a&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign="top" width="370"&gt; &lt;p&gt;Session #2 &lt;p&gt;&lt;strong&gt;Eliminating roundtrips: MERGE and the TABLE data type&lt;/strong&gt; by &lt;em&gt;Dinesh Priyankara (MVP)&lt;/em&gt; &lt;p&gt;Is your client application still making multiple calls to SQL Server for updating a single dataset? If so, each time the client application makes a call, it affects the network layer unnecessarily. In this session we will see how we can minimize this, passing the dataset with a single call and updating the table with a single statement. &lt;p&gt;&lt;u&gt;Dinesh blogs at&lt;/u&gt;: &lt;a href="http://dinesql.blogspot.com/"&gt;http://dinesql.blogspot.com/&lt;/a&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td&gt;&lt;/td&gt; &lt;td&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign="top"&gt; &lt;p&gt;&lt;u&gt;Where:&lt;/u&gt; &lt;p&gt;&lt;strong&gt;Microsoft Sri Lanka&lt;/strong&gt;&lt;b&gt;&lt;br&gt;&lt;strong&gt;11th Floor&lt;/strong&gt;&lt;br&gt;&lt;strong&gt;DHPL Building&lt;/strong&gt;&lt;br&gt;&lt;strong&gt;No. 42&lt;/strong&gt;&lt;br&gt;&lt;strong&gt;Nawam Mawatha&lt;/strong&gt;&lt;br&gt;&lt;strong&gt;Colombo 2&lt;/strong&gt;&lt;br&gt;&lt;strong&gt;SRI LANKA&lt;/strong&gt;&lt;/b&gt; &lt;p&gt;&lt;u&gt;When:&lt;/u&gt; &lt;p&gt;&lt;strong&gt;January 18th (WEDNESDAY), 2012&lt;/strong&gt;&lt;b&gt;&lt;br&gt;&lt;strong&gt;6:00 PM Onwards&lt;/strong&gt;&lt;/b&gt; &lt;p&gt;&lt;u&gt;Who:&lt;/u&gt; &lt;p&gt;&lt;strong&gt;Everyone are welcome&lt;/strong&gt;. Entrance: &lt;strong&gt;FREE&lt;/strong&gt; &lt;p&gt;&lt;u&gt;Map:&lt;/u&gt; &lt;p&gt;&lt;a href="http://maps.google.com/maps/ms?ie=UTF8&amp;amp;hl=en&amp;amp;msa=0&amp;amp;msid=209659948699567748439.00047fa8a99ae9bf0942e&amp;amp;ll=6.919131,79.853101&amp;amp;spn=0.004527,0.008256&amp;amp;z=18&amp;amp;iwloc=00047fa8ad43242303d44"&gt;CLICK HERE FOR MAP&lt;/a&gt; &lt;p&gt;&lt;u&gt;More Information:&lt;/u&gt; &lt;p&gt;&lt;strong&gt;&lt;a href="http://sqlserveruniverse.com/v2/ssslug.apx"&gt;SS SLUG Home Page&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-1954863550041674498?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/ss-slug-january-2012-meetup.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-2232975180543735335</guid><pubDate>Mon, 16 Jan 2012 11:25:00 +0000</pubDate><atom:updated>2012-01-16T16:55:44.098+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">SQL Server 2008</category><category domain="http://www.blogger.com/atom/ns#">Administration</category><category domain="http://www.blogger.com/atom/ns#">SQL Server Agent</category><title>Finding Running SQL Server Agent Jobs</title><description>&lt;p&gt;Monitoring SQL Server agent jobs is a critical task for DBAs. There are several ways of achieving this. Read this &lt;a href="http://www.sql-server-performance.com/2012/finding-running-sql-server-agent-jobs/" target="_blank"&gt;FAQ&lt;/a&gt; to find them.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-2232975180543735335?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/finding-running-sql-server-agent-jobs.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-4766115897249134300</guid><pubDate>Sun, 15 Jan 2012 08:01:00 +0000</pubDate><atom:updated>2012-01-15T13:31:03.112+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">SSIS</category><category domain="http://www.blogger.com/atom/ns#">SQL Server 2012</category><title>Favorites in SSIS</title><description>&lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;In SSIS sometimes it will be difficult to select correct task since there are lots of tasks. In SQL Server 2012 a.k.a. Denali there is a favorites so that it is easy to pick frequently used tasks.&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;Control Flow&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-7HnO0s-nF-w/TxKHq6VqblI/AAAAAAAAAZg/qPV9PSjOEO0/s1600-h/image%25255B3%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-I8PM16DRZHs/TxKHr10VnnI/AAAAAAAAAZo/3HEX9MNeOIM/image_thumb%25255B1%25255D.png?imgmax=800" width="318" height="128"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Data Flow&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-utieahiOms8/TxKHs4xVFXI/AAAAAAAAAZw/bxxhTM-wNqc/s1600-h/image%25255B9%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-G6rEtdcLuTY/TxKHtz0vINI/AAAAAAAAAZ4/BYVRJXGOpCQ/image_thumb%25255B5%25255D.png?imgmax=800" width="321" height="134"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;You can move the task to favorites by right clicking the task and automatically most used task will be moved.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-mqmquhqKQOQ/TxKHusLTS_I/AAAAAAAAAZ8/GfFpgbQjHDc/s1600-h/image%25255B13%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-NCCQizetX-U/TxKHvdSzXkI/AAAAAAAAAaE/5B_OA69n9MI/image_thumb%25255B7%25255D.png?imgmax=800" width="282" height="140"&gt;&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-4766115897249134300?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/favorites-in-ssis.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh3.ggpht.com/-I8PM16DRZHs/TxKHr10VnnI/AAAAAAAAAZo/3HEX9MNeOIM/s72-c/image_thumb%25255B1%25255D.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-7223904208759286865</guid><pubDate>Fri, 13 Jan 2012 05:44:00 +0000</pubDate><atom:updated>2012-01-13T11:14:31.073+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Fun</category><title>SQL 2012 Wallpapers</title><description>&lt;p&gt; @SQLSserver account posted 4 new wallpapers for SQL Server 2012&lt;/p&gt; &lt;p&gt;1024x768&lt;/p&gt; &lt;p&gt;&lt;a href="http://twitpic.com/7d7y08/full"&gt;http://twitpic.com/7d7y08/full&lt;/a&gt;&lt;/p&gt; &lt;p&gt;1280x800&lt;/p&gt; &lt;p&gt;&lt;a href="http://twitpic.com/7d7x8d/full"&gt;http://twitpic.com/7d7x8d/full&lt;/a&gt;&lt;/p&gt; &lt;p&gt;1400x900&lt;/p&gt; &lt;p&gt;&lt;a href="http://twitpic.com/7d7wiy/full"&gt;http://twitpic.com/7d7wiy/full&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;br&gt;1680x1024&lt;/p&gt; &lt;p&gt;&lt;a href="http://twitpic.com/7d7vwh/full"&gt;http://twitpic.com/7d7vwh/full&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Ideal for the background of your presentation VMs,&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-7223904208759286865?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/sql-2012-wallpapers.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-2377335454690966123</guid><pubDate>Mon, 09 Jan 2012 02:52:00 +0000</pubDate><atom:updated>2012-01-09T08:22:49.136+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Administration</category><category domain="http://www.blogger.com/atom/ns#">FAQ</category><category domain="http://www.blogger.com/atom/ns#">Development</category><title>How to Differentiate System and User Databases In SQL Server?</title><description>&lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;This question is frequently asked in many forums and the most popular answer is to use the DB_ID() function which is not exactly correct. This &lt;a href="http://www.sql-server-performance.com/2012/differentiate-system-user-databases/" target="_blank"&gt;FAQ&lt;/a&gt; shows how you can do that perfectly. &lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-2377335454690966123?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2012/01/how-to-differentiate-system-and-user.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-4908527969906594657</guid><pubDate>Sun, 25 Dec 2011 16:45:00 +0000</pubDate><atom:updated>2011-12-25T22:15:09.307+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">Development</category><category domain="http://www.blogger.com/atom/ns#">SQL Server 2012</category><title>New T-SQL Features in SQL Server 2012</title><description>&lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;In every version of SQL Server new T-SQL features are introduced. These are new T-SQL features of SQL Server 2012.&lt;/p&gt; &lt;ul&gt; &lt;li&gt;Sequences &lt;li&gt;Function &lt;ul&gt; &lt;li&gt;String function CONCAT,FORMAT&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;Logical function CHOOSE,IIF&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;Date &amp;amp; time function &lt;ul&gt; &lt;li&gt;DATEFROMPARTS &lt;li&gt;DATETIMEFROMPARTS&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;DATETIME2FROMPARTS&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;DATETIMEOFFSETFROMPARTS &lt;li&gt;SMALLDATETIMEFROMPARTS&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;TIMEFROMPARTS&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;EOMONTH&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;Conversion function &lt;ul&gt; &lt;li&gt;PARSE &lt;li&gt;TRY_CONVERT &lt;li&gt;TRY_PARSE &lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;Paging Data&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;Lag &amp;amp; Lead&lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;Exception handling &lt;/li&gt;&lt;/ul&gt; &lt;ul&gt; &lt;li&gt;WithResultSets&lt;/li&gt;&lt;/ul&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-4908527969906594657?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/12/new-t-sql-features-in-sql-server-2012.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-7952774803089649767</guid><pubDate>Fri, 23 Dec 2011 18:20:00 +0000</pubDate><atom:updated>2011-12-23T23:50:25.626+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Administration</category><category domain="http://www.blogger.com/atom/ns#">Development</category><category domain="http://www.blogger.com/atom/ns#">SQL Server 2012</category><category domain="http://www.blogger.com/atom/ns#">BI</category><title>Sample Databases for SQL Server 2012 RC0</title><description>&lt;p&gt;&amp;nbsp; &lt;p&gt;Sample databases dedicated to SQL Server 2012 RC0 are released. AdventureWorks2008R2_Data.mdf and AdventureWorksDWDenali_Data.mdf are those files. You need to attach these mdf files to your SQL Server instance.  &lt;p&gt;Download these sample data files from &lt;a href="http://msftdbprodsamples.codeplex.com/releases/view/55330#DownloadId=165399" target="_blank"&gt;here&lt;/a&gt;.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-7952774803089649767?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/12/sample-databases-for-sql-server-2012.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-8423312459126127893</guid><pubDate>Tue, 20 Dec 2011 17:35:00 +0000</pubDate><atom:updated>2011-12-20T23:05:06.060+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">Instalation</category><category domain="http://www.blogger.com/atom/ns#">SQL Server 2012</category><title>New Express Edition : LocalDB</title><description>&lt;p&gt;New to the Express family, LocalDB is a lightweight version of Express that has all its programmability features, yet runs in user mode and has a fast, zero-configuration installation and short list of pre-requisites. Use this if you need a simple way to create and work with databases from code. It can be bundled with Visual Studio, other Database Development tools, or embedded with an application that needs local databases.&lt;/p&gt; &lt;p&gt;&lt;a title="Download it now" href="http://www.microsoft.com/betaexperience/pd/SQLEXPCTAV2/enus/default.aspx"&gt;Try it here today!&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-8423312459126127893?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/12/new-express-edition-localdb.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-4793708998334966085</guid><pubDate>Mon, 19 Dec 2011 11:43:00 +0000</pubDate><atom:updated>2011-12-19T17:13:59.282+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Administration</category><category domain="http://www.blogger.com/atom/ns#">FAQ</category><title>Drop a Database by Closing Existing Connections using SSMS or T-SQL</title><description>&lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;Dropping database from SQL Server is not a major task. However, it can be painful if that database is being used at time of dropping it. Read this &lt;a href="http://www.sql-server-performance.com/2011/drop-database-closing-existing-connections-ssms-tsql/" target="_blank"&gt;FAQ&lt;/a&gt; from &lt;a href="http://www.sql-server-performance.com"&gt;www.sql-server-performance.com&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-4793708998334966085?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/12/drop-database-by-closing-existing.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-6953059197219562941</guid><pubDate>Wed, 14 Dec 2011 14:13:00 +0000</pubDate><atom:updated>2011-12-14T19:43:47.837+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">SQL Server 2008</category><category domain="http://www.blogger.com/atom/ns#">Administration</category><category domain="http://www.blogger.com/atom/ns#">Bugs</category><title>Two SPIDs in sp_who2</title><description>&lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;sp_who2 is function you can use to identify who (Login) is running at what (DBName, command) from where (SPID &amp;amp; Host) as you can see in the following image.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-2hmE0tNQC1I/Tuiu2n2qUvI/AAAAAAAAAYk/K8qp490EfW4/s1600-h/image3.png"&gt;&lt;img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-_TUkIAmsiCw/Tuiu4Ni_mAI/AAAAAAAAAYs/jGSzZqGvtBE/image_thumb1.png?imgmax=800" width="526" height="176"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;If you look closely, you will see that there are two SPID columns with same values. By looking at them, they are same So let us see the coding of this.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-AD1XpdxPuOA/Tuiu5ToXXnI/AAAAAAAAAY0/sUhbHzPCp2Q/s1600-h/image5.png"&gt;&lt;img style="background-image: none; border-right-width: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-7jAmk8SfdhA/Tuiu66_Mv0I/AAAAAAAAAY8/LoNM-BsyjqY/image_thumb2.png?imgmax=800" width="525" height="194"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;So you would see that SPID column is convert(char(5),spid) so why on earth same column twice.&lt;/p&gt; &lt;p&gt;Just see the comment after second SPID.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;&lt;font style="" color="#ff0000" size="4"&gt;Handy extra for right-scrolling users.&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Do you agree. I am not &lt;img style="border-bottom-style: none; border-left-style: none; border-top-style: none; border-right-style: none" class="wlEmoticon wlEmoticon-smile" alt="Smile" src="http://lh4.ggpht.com/-mydv9pMFSds/Tuiu7qRZizI/AAAAAAAAAZE/Dbyfu5RC3wA/wlEmoticon-smile%25255B2%25255D.png?imgmax=800"&gt; .&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-6953059197219562941?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/12/two-spids-in-spwho2.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh4.ggpht.com/-_TUkIAmsiCw/Tuiu4Ni_mAI/AAAAAAAAAYs/jGSzZqGvtBE/s72-c/image_thumb1.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-2700448251912448953</guid><pubDate>Mon, 12 Dec 2011 03:35:00 +0000</pubDate><atom:updated>2011-12-12T09:05:54.518+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">Video</category><category domain="http://www.blogger.com/atom/ns#">SQL Server 2012</category><title>SQL Server 2012 Training Videos on Channel9.MSDN.COM</title><description>&lt;p&gt;&amp;nbsp; &lt;p&gt;PowerPivot and Power View Lifecycle and BI Semantic Model (BISM) Overview &lt;p&gt;&lt;a href="http://channel9.msdn.com/posts/SQL-Shorts-PowerPivot-and-Power-View-Lifecycle-and-BI-Semantic-Model-BISM-Overview"&gt;http://channel9.msdn.com/posts/SQL-Shorts-PowerPivot-and-Power-View-Lifecycle-and-BI-Semantic-Model-BISM-Overview&lt;/a&gt; &lt;p&gt;AlwaysOn SQL 2012 &lt;p&gt;&lt;a href="http://channel9.msdn.com/Blogs/mwilmot/SQLShorts-AlwaysOn-SQL-2012"&gt;http://channel9.msdn.com/Blogs/mwilmot/SQLShorts-AlwaysOn-SQL-2012&lt;/a&gt; &lt;p&gt;AlwaysOn Availability Groups for SQL 2012 &lt;p&gt;&lt;a href="http://channel9.msdn.com/posts/SQLShorts--AlwaysOn-Availability-Groups-for-SQL-2012"&gt;http://channel9.msdn.com/posts/SQLShorts--AlwaysOn-Availability-Groups-for-SQL-2012&lt;/a&gt; &lt;p&gt;SQL 2012 Apollo Column Store  &lt;p&gt;&lt;a href="http://channel9.msdn.com/posts/SQLShorts-SQL-2012-Apollo-Column-Store"&gt;http://channel9.msdn.com/posts/SQLShorts-SQL-2012-Apollo-Column-Store&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-2700448251912448953?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/12/sql-server-2012-training-videos-on.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-3258811387218002879</guid><pubDate>Tue, 29 Nov 2011 18:46:00 +0000</pubDate><atom:updated>2011-11-30T00:16:56.244+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Speaking Engagement</category><title>TechInsights 2011</title><description>&lt;p&gt;I was a speaker at &lt;a href="http://www.techinsights.my/"&gt;TechInsights 2011&lt;/a&gt; which was held in Malaysia at Monash University Kuala Lampur. &lt;/p&gt; &lt;p&gt;Well, this is my first appearance out side Sri Lanka and was a great experience. &lt;/p&gt; &lt;p&gt;I did two sessions 1. CDC for SCD and 2. Resource Governor. To be honest, first session was not much participated second one was far better.&lt;/p&gt; &lt;p&gt;Here are few photos of the sessions.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-voR9KO9GzwM/TtUoauS_K-I/AAAAAAAAAXk/01euUHQCa9k/s1600-h/TI2%25255B2%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="TI2" border="0" alt="TI2" src="http://lh6.ggpht.com/-XRnikFGgnZo/TtUocOuQu5I/AAAAAAAAAXs/BAhs3zyiHno/TI2_thumb.jpg?imgmax=800" width="184" height="244"&gt;&lt;/a&gt;&lt;a href="http://lh5.ggpht.com/-zVl6M_RLWs0/TtUoeoJloCI/AAAAAAAAAX0/dcGbKxoolos/s1600-h/TI3%25255B2%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="TI3" border="0" alt="TI3" src="http://lh4.ggpht.com/-m8NwKy1Qwx8/TtUogQPphaI/AAAAAAAAAX8/20lL1M5N1nM/TI3_thumb.jpg?imgmax=800" width="184" height="244"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-_bOiDm6BWqU/TtUoiKtcS2I/AAAAAAAAAYE/hs7XVzLcXjA/s1600-h/TI1%25255B2%25255D.jpg"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="TI1" border="0" alt="TI1" src="http://lh3.ggpht.com/-cjOf1xq7Xfo/TtUojnH3oEI/AAAAAAAAAYI/80mb_yVu_rE/TI1_thumb.jpg?imgmax=800" width="163" height="244"&gt;&lt;/a&gt;&lt;a href="http://lh3.ggpht.com/-OJAGesKoRp8/TtUomGA9dfI/AAAAAAAAAYU/16KU_KV7uUc/s1600-h/TI4%25255B5%25255D.jpg"&gt;&lt;img style="display: inline" title="TI4" alt="TI4" src="http://lh3.ggpht.com/-Kc_GRk-j1oI/TtUonSSw4SI/AAAAAAAAAYc/ZQABy69xCFw/TI4_thumb%25255B3%25255D.jpg?imgmax=800" width="240" height="160"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Here are &lt;a href="https://skydrive.live.com/?cid=22a79fce82651673&amp;amp;id=22A79FCE82651673%212321"&gt;Presentations and Samples&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-3258811387218002879?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/11/techinsights-2011.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh6.ggpht.com/-XRnikFGgnZo/TtUocOuQu5I/AAAAAAAAAXs/BAhs3zyiHno/s72-c/TI2_thumb.jpg?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-42597327167398758</guid><pubDate>Fri, 18 Nov 2011 19:16:00 +0000</pubDate><atom:updated>2011-11-19T00:46:17.118+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><title>SQL Server 2012 RC0</title><description>&lt;p&gt;SQL Server 2012 Release Candidate 0 is now available for download. SQL Server 2012 RC0 (previously code-named Denali) includes several new capabilities (most of which are related to the release’s new features) that weren’t available in SQL Server Denali CTP3, including the following: &lt;ul&gt; &lt;li&gt;AlwaysOn—SQL Server 2012 RC0 offers multiple readable secondaries in AlwaysOn, which lets you better distribute backup and reporting workloads, and it now supports the FileTable and FILESTREAM data types.  &lt;li&gt;Resource Governor—According the &lt;a href="http://blogs.technet.com/b/dataplatforminsider/archive/2011/11/17/sql-server-2012-release-candidate-is-now-available.aspx"&gt;SQL Server Team Blog&lt;/a&gt;, SQL Server 2012’s Resource Governor includes several new capabilities, including support for 64 resource pools, enhanced CPU usage controls, and enhanced resource allocation.  &lt;li&gt;Cloud Computing—SQL Server Management Studio (SSMS) now supports snapshot backups to Windows Azure.  &lt;li&gt;Data Quality Services and Master Data Services—This release provides Change Data Capture (CDC) support for Oracle.  &lt;li&gt;Power View—The data visualization tool includes new features with SQL Server 2012 RC0.&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;For more information about the upcoming release of SQL Server, see &lt;a href="http://www.microsoft.com/sqlserver/en/us/future-editions.aspx"&gt;Microsoft’s SQL Server 2012 page&lt;/a&gt;. You can &lt;a href="http://www.microsoft.com/download/en/details.aspx?id=28145"&gt;download SQL Server 2012 RC0 here&lt;/a&gt;.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-42597327167398758?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/11/sql-server-2012-release-candidate-0-is.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>1</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-4846621148453963449</guid><pubDate>Sun, 13 Nov 2011 15:49:00 +0000</pubDate><atom:updated>2011-11-13T21:19:10.977+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">Development</category><title>Combining Columns Ignoring Null Columns</title><description>&lt;p&gt;Let’s start with an example.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-sO5IULdDycI/Tr_mmsGxuCI/AAAAAAAAAV0/DHGUzkdAWbE/s1600-h/image%25255B4%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-KHfjH2gTMus/Tr_mpR0BApI/AAAAAAAAAV8/DTUbpdDCqmc/image_thumb%25255B2%25255D.png?imgmax=800" width="427" height="369"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;You will see that MiddleName column has NULL values. If you want to combine all four columns and display them in one column you will write following query.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-PK5O2NOFzg0/Tr_mqgNnNvI/AAAAAAAAAWE/jT2w0Mhtpdg/s1600-h/image%25255B8%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-JBH1b_f0eIk/Tr_msUIHCeI/AAAAAAAAAWM/WENvl27JjHE/image_thumb%25255B4%25255D.png?imgmax=800" width="284" height="142"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Result is,&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-MJqzi9ZGrks/Tr_mtjs5skI/AAAAAAAAAWU/j8PygTcQVqw/s1600-h/image%25255B12%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-GvY0ARVM-is/Tr_mvs6jfFI/AAAAAAAAAWc/wNYCCpCF5fI/image_thumb%25255B6%25255D.png?imgmax=800" width="215" height="232"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;You will realize the obvious problems from the above result set. To avoid this what you should is, use the ISNULL function.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-3B3PsmPXAvs/Tr_mw7hOCVI/AAAAAAAAAWk/roFMgg-OX5Y/s1600-h/image%25255B16%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-JPJ1TJIT9CQ/Tr_mytmR6zI/AAAAAAAAAWs/R1ETiUNPZ-M/image_thumb%25255B8%25255D.png?imgmax=800" width="318" height="113"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Though the above will solve your problem, as a developer you need to keep an eye on nullability of the column.&lt;/p&gt; &lt;p&gt;With Denali, you have a new function called CONCAT.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-oK5JobbzEf8/Tr_mzukVdhI/AAAAAAAAAW0/VOabo1bB0zo/s1600-h/image%25255B20%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-Y6S6zerF4kw/Tr_m1aVotFI/AAAAAAAAAW8/lnjajofj9sA/image_thumb%25255B10%25255D.png?imgmax=800" width="382" height="56"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;And the result is,&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-i16Zhp0iXhI/Tr_m2z69lzI/AAAAAAAAAXE/r3ZmCp17jkQ/s1600-h/image%25255B25%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-cPy38rNTp7Y/Tr_m5Crh2LI/AAAAAAAAAXM/EcMt0GPRKPY/image_thumb%25255B13%25255D.png?imgmax=800" width="181" height="350"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;which is what we were looking for.&lt;/p&gt; &lt;p&gt;Next question is, how about the performance.&lt;/p&gt; &lt;p&gt;To answer that I will display query execution plans for two queries, one with CONCAT and the other with ISNULL function.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-ZaRKk5T7HSQ/Tr_m612ddfI/AAAAAAAAAXU/wNjA6PxFcbU/s1600-h/image%25255B31%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-uNRp1jDNHrk/Tr_m80zqtrI/AAAAAAAAAXc/W9y-hGIH5yI/image_thumb%25255B17%25255D.png?imgmax=800" width="437" height="218"&gt;&lt;/a&gt;&lt;/p&gt;       &lt;p&gt;So there is no additional cost with the new function.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-4846621148453963449?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/11/combining-columns-ignoring-null-columns.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh6.ggpht.com/-KHfjH2gTMus/Tr_mpR0BApI/AAAAAAAAAV8/DTUbpdDCqmc/s72-c/image_thumb%25255B2%25255D.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-7588441545239332362</guid><pubDate>Sat, 05 Nov 2011 18:10:00 +0000</pubDate><atom:updated>2011-11-05T23:40:40.757+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">Editions</category><category domain="http://www.blogger.com/atom/ns#">Licensing</category><title>SQL Server 2012 Editions</title><description>&lt;p&gt;SQL Server 2012 users will experience new SQL Server editions called Business Intelligence&amp;nbsp; to the addition of existing editions, Enterprise, Standard, Web , Developer, Express and Evolution.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-XqPuEmrPYNc/TrV8CPoVuGI/AAAAAAAAAVE/txT1hhLAncs/s1600-h/image%25255B6%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-g9w2M7UXmh8/TrV8DQ5XxCI/AAAAAAAAAVM/YPDukkmQO5Y/image_thumb%25255B4%25255D.png?imgmax=800" width="533" height="279"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-e17m0Iatn_U/TrV8ENY3BHI/AAAAAAAAAVU/HAmvvkU-4AA/s1600-h/image%25255B11%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-6YDnKMwCCEY/TrV8FMy_pPI/AAAAAAAAAVc/vVzApPuiB0k/image_thumb%25255B7%25255D.png?imgmax=800" width="524" height="220"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-nvAfDLy88aU/TrV8GTYtFzI/AAAAAAAAAVk/cYdPxBgyzVc/s1600-h/image%25255B17%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-V_5iWfdMQ5Q/TrV8Hos7PWI/AAAAAAAAAVs/iOEleQC6wUc/image_thumb%25255B11%25255D.png?imgmax=800" width="507" height="283"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;If you wish for more news about &lt;a href="http://www.microsoft.com/sqlserver/en/us/future-editions/sql2012-editions.aspx"&gt;editions&lt;/a&gt; and &lt;a href="http://www.microsoft.com/sqlserver/en/us/future-editions/sql2012-licensing.aspx"&gt;licensing&lt;/a&gt; click it here.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-7588441545239332362?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/11/sql-server-2012-editions.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh6.ggpht.com/-g9w2M7UXmh8/TrV8DQ5XxCI/AAAAAAAAAVM/YPDukkmQO5Y/s72-c/image_thumb%25255B4%25255D.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-5653475077756735137</guid><pubDate>Mon, 31 Oct 2011 10:51:00 +0000</pubDate><atom:updated>2011-10-31T16:21:47.675+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Denali</category><category domain="http://www.blogger.com/atom/ns#">Development</category><title>TRY_CONVERT</title><description>&lt;p&gt;I am sure you would have used CONVERT function many times. &lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-WOhBfUdmO8s/Tq59kxS0jCI/AAAAAAAAAT0/3_0g-pxvI2Y/s1600-h/image%25255B3%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-_KAVF5-TkIQ/Tq59mcnYErI/AAAAAAAAAT8/Oy83kIPAjbs/image_thumb%25255B1%25255D.png?imgmax=800" width="275" height="233"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;If you see the above data set, last date value is an invalid date. If you are integrating with legacy systems, you will these types of records. &lt;/p&gt; &lt;p&gt;They you might need to convert these into a date time value. Naturally, you will use, CONVERT function.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh3.ggpht.com/-Fp_CeJCO9wI/Tq59nvouJZI/AAAAAAAAAUE/-C0tU5IzLFk/s1600-h/image%25255B7%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-4ZYJPdaYjUY/Tq59o2Bq9uI/AAAAAAAAAUM/qyZLVV-q5Fk/image_thumb%25255B3%25255D.png?imgmax=800" width="278" height="47"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;But it will fail.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-NjtmIgoKi1o/Tq59pzUcLHI/AAAAAAAAAUQ/IyF5XI5-SxI/s1600-h/image%25255B11%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-hmDfPRzBKr0/Tq59rR2mm4I/AAAAAAAAAUc/A1OHBw_WCBU/image_thumb%25255B5%25255D.png?imgmax=800" width="288" height="38"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;In Denali or SQL Server 2012 (as per CTP3) you have new function called TRY_CONVERT.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-zEpKmRDS9LQ/Tq59scTKPAI/AAAAAAAAAUk/XpyvxK4YjQU/s1600-h/image%25255B15%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-wtnfuJ8pekk/Tq59t5o26xI/AAAAAAAAAUs/auZtk4GXgXY/image_thumb%25255B7%25255D.png?imgmax=800" width="321" height="157"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;With this new function, you won’t get the error as well as you will be able to find out the errors as well.&lt;/p&gt; &lt;p&gt;Following query will return all the rows where you have an invalid date value.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-Ybuk4eY7sVo/Tq59vKtPvQI/AAAAAAAAAU0/Io73IB-4Pcs/s1600-h/image%25255B19%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-cOckCWLsfhI/Tq59wUPJRfI/AAAAAAAAAU8/jwIrYfIDADA/image_thumb%25255B9%25255D.png?imgmax=800" width="300" height="145"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;You can use this for other data types as well.&lt;/p&gt; &lt;p&gt;Download the code from &lt;a href="https://skydrive.live.com/?cid=22a79fce82651673&amp;amp;sc=documents&amp;amp;uc=1&amp;amp;id=22A79FCE82651673%212297#" target="_blank"&gt;here&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-5653475077756735137?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/10/tryconvert.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh4.ggpht.com/-_KAVF5-TkIQ/Tq59mcnYErI/AAAAAAAAAT8/Oy83kIPAjbs/s72-c/image_thumb%25255B1%25255D.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-1662037218504145024</guid><pubDate>Sun, 16 Oct 2011 10:49:00 +0000</pubDate><atom:updated>2011-10-16T16:19:01.967+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">SQL Server 2008</category><category domain="http://www.blogger.com/atom/ns#">Service Packs</category><title>SQL Server 2008 SP3 is now available!</title><description>&lt;p&gt;Microsoft SQL Server Sustained Engineering group is pleased to announce the release of SQL Server 2008 Service Pack 3 (SP3). Both the Service Pack and Feature Pack updates are available for download on the Microsoft Download Center. As part of our continued commitment to software excellence for our customers, this upgrade is free and doesn’t require an additional service contract.&lt;/p&gt; &lt;p&gt;Download it from &lt;a href="http://blogs.msdn.com/b/sqlreleaseservices/archive/2011/10/06/sql-server-2008-sp3-is-now-available.aspx" target="_blank"&gt;here&lt;/a&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-1662037218504145024?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/10/sql-server-2008-sp3-is-now-available.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-4044017235517810190</guid><pubDate>Fri, 30 Sep 2011 04:19:00 +0000</pubDate><atom:updated>2011-09-30T09:49:09.526+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Replication</category><category domain="http://www.blogger.com/atom/ns#">Administration</category><category domain="http://www.blogger.com/atom/ns#">FAQ</category><title>Failing of alter Table statement</title><description>&lt;p&gt;Replication Agent will fail when attempting to alter a column in the publisher which is part of an index.&lt;/p&gt; &lt;p&gt;Here is the &lt;a href="http://www.sql-server-performance.com/2011/sql-server-agent-alter-column-error/" target="_blank"&gt;faq&lt;/a&gt; of mine.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-4044017235517810190?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/09/failing-of-alter-table-statement.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-696166865776998162</guid><pubDate>Wed, 31 Aug 2011 16:50:00 +0000</pubDate><atom:updated>2011-09-07T15:34:45.732+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Development</category><category domain="http://www.blogger.com/atom/ns#">si-lk</category><title>දත්ත මූලිකයන්හි සිංහලෙන් දත්ත ගබඩා කරමු</title><description>&lt;p&gt;මෙය මවිසින් ලියන ලද දෙවැනි ලිපියයි.&lt;/p&gt;&lt;p&gt;මෑතකදී, විශ්ව විද්‍යාලයක සිසුන් පිරිසක් තම පාඨමාලවේ පර්යේෂන වියාපෘතියකට ශ්‍රි ලංකා පොලීසිය සදහා ලැබෙන සුළු අපරාධ විශ්ලේශණය කිරීම තෝරා ගෙන තිබුනි. ඒ සදහා ඔවුන් සිංහලෙන් දත්ත ගබඩා කිරිමට තෝරා ගෙන තිබිනි. එයට මූලික හේතුව වී තිබුනේ, ලැබෙන දත්ත භාවිතා කරන අයට ඉංග්‍රීසි භාවිතයට වඩා සිංහල පහසු නිසාය. බොහෝ ශ්‍රි ලංකාවේ රාජ්‍ය ආයතයන් හි මෙම තත්වය ඇති බැවින්, ඒ පිළිබදව කිසියම් විස්තරයක් කිරීම මෙම ලිපියෙහි අරමුණයි. &lt;p&gt;&lt;a href="http://social.technet.microsoft.com/wiki/contents/articles/4333.aspx" target="http://social.technet.microsoft.com/wiki/contents/articles/4333.aspx"&gt;දත්ත මූලිකයන්හි සිංහලෙන් දත්ත ගබඩා කරමු&lt;/a&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-696166865776998162?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/08/blog-post.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-440553866118194390</guid><pubDate>Tue, 30 Aug 2011 17:20:00 +0000</pubDate><atom:updated>2011-08-30T22:50:26.196+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Administration</category><title>Change the case of the Logical Name of a SQL Server Database</title><description>&lt;p&gt;When you create a database, by default data file and log file will be added to the database. For logical name it will be, &lt;strong&gt;Databasename_log. &lt;/strong&gt;Let us say you want to change it to &lt;strong&gt;Database_Log (where L is in upper case).&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;&lt;strong&gt;ALTER DATABASE [TailLog] &lt;br&gt;MODIFY FILE (NAME=N'TailLog_log', NEWNAME=N'TailLog_Log')&lt;br&gt;GO&lt;/strong&gt;&lt;br&gt;&lt;/p&gt; &lt;p&gt;Then you will get an following error.&lt;/p&gt; &lt;p&gt;&lt;font color="#ff0000"&gt;Msg 1828, Level 16, State 3, Line 1&lt;br&gt;The logical file name "TailLog_Log" is already in use. Choose a different name.&lt;/font&gt;&lt;/p&gt; &lt;p&gt;Let us try to do this from the SSMS.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-s2wEa49x2-o/Tl0bzu4eWUI/AAAAAAAAATg/w5piLtGFBmg/s1600-h/image%25255B8%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh5.ggpht.com/-7IiY6-b7ex4/Tl0b2I6jwJI/AAAAAAAAATk/I78v_gnI0pc/image_thumb%25255B4%25255D.png?imgmax=800" width="446" height="202"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;So basically you are not allow to do this. &lt;/p&gt; &lt;p&gt;What you have to do is, first set it to another name.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;ALTER DATABASE [TailLog] &lt;br&gt;MODIFY FILE (NAME=N'TailLog_log', NEWNAME=N'TailLog_LogTemp')&lt;br&gt;GO&lt;br&gt;&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;The file name 'TailLog_LogTemp' has been set.&lt;/p&gt; &lt;p&gt;Then change it back to TailLog_Log so that you can achieve your target.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;ALTER DATABASE [TailLog] &lt;br&gt;MODIFY FILE (NAME=N'TailLog_LogTemp', NEWNAME=N'TailLog_Log')&lt;br&gt;GO&lt;/strong&gt;&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-440553866118194390?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/08/change-case-of-logical-name-of-sql.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh5.ggpht.com/-7IiY6-b7ex4/Tl0b2I6jwJI/AAAAAAAAATk/I78v_gnI0pc/s72-c/image_thumb%25255B4%25255D.png?imgmax=800" height="72" width="72" /><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2377727724851115192.post-746730728675889285</guid><pubDate>Sat, 27 Aug 2011 12:40:00 +0000</pubDate><atom:updated>2011-08-27T18:10:48.299+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">SQL Server 2008</category><category domain="http://www.blogger.com/atom/ns#">Administration</category><category domain="http://www.blogger.com/atom/ns#">SQL Server 2008 R2</category><category domain="http://www.blogger.com/atom/ns#">Bugs</category><title>Disk Usage Report in SSMS</title><description>&lt;p&gt;Reports in SSMS are very helpful when monitoring SQL Server. But today I encounter an issue with one of the reports, which is Disk Usage Report. &lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-RQkugXJaVrs/Tljlf8ymWmI/AAAAAAAAASg/MVJXnjUCY54/s1600-h/image%25255B2%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-90Ghe4LtjPI/TljlhKqNBZI/AAAAAAAAASk/cTXqZVU0mqo/image_thumb.png?imgmax=800" width="244" height="159"&gt;&lt;/a&gt;&lt;a href="http://lh5.ggpht.com/-VSa5Rid7otw/TljliexHF6I/AAAAAAAAASo/KpaVSoMUEtQ/s1600-h/image%25255B5%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/-PSy_xX6tmVo/Tljljq3rX0I/AAAAAAAAASs/tulyqO6wIjY/image_thumb%25255B1%25255D.png?imgmax=800" width="244" height="145"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Above is the Transaction Log space usage report taken for same database but for different times. Actually, second one was after taking a log backup. After seeing this report my immediate reaction was log backup has not cleared the log. So I ran another log backup and results are similar. But when you analyze these graphs carefully you would see that in the first graph, Green is Used and in the second Green is Unused and Blue is vice-versa. (Oops).&lt;/p&gt; &lt;p&gt;I did few more research into this to find out the tipping point and this is happening after 50% percent. See the image below.&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-ayEb_ieBxC4/Tljlk_Vl9dI/AAAAAAAAASw/gzKlRM4d780/s1600-h/image%25255B8%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-B3Tl1c7vBdA/Tljlma0Wo5I/AAAAAAAAAS0/Dt143a-B2xo/image_thumb%25255B2%25255D.png?imgmax=800" width="244" height="152"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-nMdBcZIwCVI/Tljlni9__LI/AAAAAAAAAS4/sf2iinONOwk/s1600-h/image%25255B11%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-YeD2T24Z8TA/TljlpLuvN-I/AAAAAAAAAS8/Gnvmbc3uUmQ/image_thumb%25255B3%25255D.png?imgmax=800" width="244" height="153"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh6.ggpht.com/-0IKNlC8zj98/TljlqLMR9dI/AAAAAAAAATA/CLTxJtlHi2Q/s1600-h/image%25255B14%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-8I9Man3zjXA/TljlrsOsqGI/AAAAAAAAATE/zhs2cHnj7No/image_thumb%25255B4%25255D.png?imgmax=800" width="244" height="158"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-GWo7_40xxlU/Tljls2-BClI/AAAAAAAAATI/OUfS0nUeyTc/s1600-h/image%25255B17%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh6.ggpht.com/--oPPNx4fM84/TljluPGBmcI/AAAAAAAAATM/xlgdVmbVloo/image_thumb%25255B5%25255D.png?imgmax=800" width="244" height="163"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Now it is 50-50 and next one is,&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh4.ggpht.com/-Ueiiio-pbcY/TljlvEhn0UI/AAAAAAAAATQ/Kflpsaj5BfM/s1600-h/image%25255B20%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh4.ggpht.com/-LrJMH631JU8/TljlwmS92AI/AAAAAAAAATU/et47SNMJGnU/image_thumb%25255B6%25255D.png?imgmax=800" width="244" height="153"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://lh5.ggpht.com/-DLkWl6x7hhs/Tljlx7ilzkI/AAAAAAAAATY/cfktKEvO3sE/s1600-h/image%25255B23%25255D.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://lh3.ggpht.com/-EF5-UaQJjD4/Tljlzf91MDI/AAAAAAAAATc/GtRfYHsEsfk/image_thumb%25255B7%25255D.png?imgmax=800" width="244" height="162"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;You can clearly see the change. I verified this is the same behavior in SQL Server 2008 R2 as well.&lt;/p&gt;  &lt;div class="blogger-post-footer"&gt;http://dbfriend.blogspot.com/feeds/posts/default?alt=rss&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2377727724851115192-746730728675889285?l=dbfriend.blogspot.com' alt='' /&gt;&lt;/div&gt;</description><link>http://dbfriend.blogspot.com/2011/08/disk-usage-report-in-ssms.html</link><author>noreply@blogger.com (Dinesh Asanka)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://lh6.ggpht.com/-90Ghe4LtjPI/TljlhKqNBZI/AAAAAAAAASk/cTXqZVU0mqo/s72-c/image_thumb.png?imgmax=800" height="72" width="72" /><thr:total>3</thr:total></item></channel></rss>

