<?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:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:copyright="http://blogs.law.harvard.edu/tech/rss" xmlns:image="http://purl.org/rss/1.0/modules/image/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">
    <channel>
        <title>The SQL Server Side of Me (en-us)</title>
        <link>http://weblogs.sqlteam.com/lucaz/Default.aspx</link>
        <description />
        <language>en-US</language>
        <copyright>Luca Zavarella</copyright>
        <generator>Subtext Version 2.5.1.0</generator>
        <image>
            <title>The SQL Server Side of Me (en-us)</title>
            <url>http://weblogs.sqlteam.com/images/RSS2Image.gif</url>
            <link>http://weblogs.sqlteam.com/lucaz/Default.aspx</link>
            <width>77</width>
            <height>60</height>
        </image>
        <atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/TheSqlServerSideOfMeen-us" /><feedburner:info uri="thesqlserversideofmeen-us" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
            <title>How to use a list of values in Excel as filter in a query</title>
            <category>T-SQL</category>
            <category>Excel</category>
            <category>Array</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/0UwrqL0HCQU/how-to-use-a-list-of-values-in-excel-as-filter-in-a-query.aspx</link>
            <description>&lt;p&gt;It often happens that a customer provides us with a list of items for which to extract certain information. Imagine, for example, that our clients wish to have the header information of the sales orders only for certain orders. Most likely he will give us a list of items in a column in Excel, or, less probably, a simple text file with the identification code:&lt;/p&gt;  &lt;p&gt;&lt;img style="margin: 0px 5px" src="https://lh4.googleusercontent.com/-kkoYWnd5CPI/T9Znxdb84wI/AAAAAAAAAdQ/NqdMgSV68TU/s225/List_01.png" width="177" height="158" /&gt;    &lt;img style="margin: 0px 5px" src="https://lh4.googleusercontent.com/-MfvdpC1SJvw/T9ZnxdyQ7GI/AAAAAAAAAdU/7R6pXK35yoY/s256/List_02.png" width="188" height="164" /&gt;&lt;/p&gt;  &lt;p&gt;As long as the given values ​​are at best a dozen, it costs us nothing to copy and paste those values ​​in our SSMS and place them in a WHERE clause, using the IN operator, making sure to include the quotes in the case of alphanumeric elements (the database sample is &lt;em&gt;AdventureWorks2008R2&lt;/em&gt;):&lt;/p&gt;  &lt;pre class="SQLCode"&gt;&lt;span class="SQLKeyword"&gt;SELECT&lt;/span&gt; &lt;span class="SQLOperator"&gt;*&lt;/span&gt;
&lt;span class="SQLKeyword"&gt;FROM&lt;/span&gt; Sales&lt;span class="SQLOperator"&gt;.&lt;/span&gt;SalesOrderHeader &lt;span class="SQLKeyword"&gt;AS&lt;/span&gt; SOH
&lt;span class="SQLKeyword"&gt;WHERE&lt;/span&gt; SOH&lt;span class="SQLOperator"&gt;.&lt;/span&gt;SalesOrderNumber &lt;span class="SQLOperator"&gt;IN&lt;/span&gt; &lt;span class="SQLOperator"&gt;(&lt;/span&gt;
		&lt;span class="SQLString"&gt;'SO43667'&lt;/span&gt;
		&lt;span class="SQLOperator"&gt;,&lt;/span&gt;&lt;span class="SQLString"&gt;'SO43709'&lt;/span&gt;
		&lt;span class="SQLOperator"&gt;,&lt;/span&gt;&lt;span class="SQLString"&gt;'SO43726'&lt;/span&gt;
		&lt;span class="SQLOperator"&gt;,&lt;/span&gt;&lt;span class="SQLString"&gt;'SO43746'&lt;/span&gt;
		&lt;span class="SQLOperator"&gt;,&lt;/span&gt;&lt;span class="SQLString"&gt;'SO43782'&lt;/span&gt;
		&lt;span class="SQLOperator"&gt;,&lt;/span&gt;&lt;span class="SQLString"&gt;'SO43796'&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;Clearly, the need to add commas and quotes becomes an hassle when dealing with hundreds of items (which of course has happened to us!). It’d be comfortable to do a simple copy and paste, leaving the items as they are pasted, and make sure the query works fine.&lt;/p&gt;

&lt;p&gt;We can have this commodity via a &lt;em&gt;User Defined Function&lt;/em&gt;, that returns items in a table. Simply we’ll provide the function with an input string parameter containing the pasted items. I give you directly the T-SQL code, where comments are there to clarify what was written:&lt;/p&gt;

&lt;pre class="SQLCode"&gt;&lt;font size="2"&gt;&lt;span class="SQLKeyword"&gt;CREATE&lt;/span&gt; &lt;span class="SQLKeyword"&gt;FUNCTION&lt;/span&gt; [dbo]&lt;span class="SQLOperator"&gt;.&lt;/span&gt;[SplitCRLFList] &lt;span class="SQLOperator"&gt;(&lt;/span&gt;@List &lt;span class="SQLKeyword"&gt;VARCHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;&lt;span class="SQLFunction"&gt;MAX&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
&lt;span class="SQLKeyword"&gt;RETURNS&lt;/span&gt; @ParsedList &lt;span class="SQLKeyword"&gt;TABLE&lt;/span&gt; &lt;span class="SQLOperator"&gt;(&lt;/span&gt;
	&lt;span class="SQLComment"&gt;--&amp;lt;	Set the item length as your needs	 &lt;/span&gt;
	Item &lt;span class="SQLKeyword"&gt;VARCHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;255&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
	&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
&lt;span class="SQLKeyword"&gt;AS&lt;/span&gt;
&lt;span class="SQLKeyword"&gt;BEGIN&lt;/span&gt;
	&lt;span class="SQLKeyword"&gt;DECLARE&lt;/span&gt;
		&lt;span class="SQLComment"&gt;--&amp;lt;	Set the item length as your needs&lt;/span&gt;
		@Item &lt;span class="SQLKeyword"&gt;VARCHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;255&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
		&lt;span class="SQLOperator"&gt;,&lt;/span&gt;@Pos &lt;span class="SQLKeyword"&gt;BIGINT&lt;/span&gt;

	&lt;span class="SQLComment"&gt;--&amp;lt; Trim TABs due to indentations&lt;/span&gt;
	&lt;span class="SQLKeyword"&gt;SET&lt;/span&gt; @List &lt;span class="SQLOperator"&gt;=&lt;/span&gt; &lt;span class="SQLFunction"&gt;REPLACE&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;@List&lt;span class="SQLOperator"&gt;,&lt;/span&gt; &lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;9&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;,&lt;/span&gt; &lt;span class="SQLString"&gt;''&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
	&lt;span class="SQLComment"&gt;--&amp;lt; Trim leading and trailing spaces, then add a CR\LF at the end of the list&lt;/span&gt;
	&lt;span class="SQLKeyword"&gt;SET&lt;/span&gt; @List &lt;span class="SQLOperator"&gt;=&lt;/span&gt; &lt;span class="SQLFunction"&gt;LTRIM&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;&lt;span class="SQLFunction"&gt;RTRIM&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;@List&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLOperator"&gt;+&lt;/span&gt; &lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;13&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLOperator"&gt;+&lt;/span&gt; &lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;10&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
	&lt;span class="SQLComment"&gt;--&amp;lt; Set the position at the first CR/LF in the list&lt;/span&gt;
	&lt;span class="SQLKeyword"&gt;SET&lt;/span&gt; @Pos &lt;span class="SQLOperator"&gt;=&lt;/span&gt; &lt;span class="SQLFunction"&gt;CHARINDEX&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;&lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;13&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLOperator"&gt;+&lt;/span&gt; &lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;10&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;,&lt;/span&gt; @List&lt;span class="SQLOperator"&gt;,&lt;/span&gt; 1&lt;span class="SQLOperator"&gt;)&lt;/span&gt;

	&lt;span class="SQLComment"&gt;--&amp;lt; If exist other chars other than CR/LFs in the list then...	&lt;/span&gt;
	&lt;span class="SQLKeyword"&gt;IF&lt;/span&gt; &lt;span class="SQLFunction"&gt;REPLACE&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;@List&lt;span class="SQLOperator"&gt;,&lt;/span&gt; &lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;13&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLOperator"&gt;+&lt;/span&gt; &lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;10&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;,&lt;/span&gt; &lt;span class="SQLString"&gt;''&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLOperator"&gt;&amp;lt;&amp;gt;&lt;/span&gt; &lt;span class="SQLString"&gt;''&lt;/span&gt;
	&lt;span class="SQLKeyword"&gt;BEGIN&lt;/span&gt;
		&lt;span class="SQLComment"&gt;--&amp;lt; Loop while CR/LFs are over (not found = CHARINDEX returns 0)&lt;/span&gt;
		&lt;span class="SQLKeyword"&gt;WHILE&lt;/span&gt; @Pos &lt;span class="SQLOperator"&gt;&amp;gt;&lt;/span&gt; 0
		&lt;span class="SQLKeyword"&gt;BEGIN&lt;/span&gt;
			&lt;span class="SQLComment"&gt;--&amp;lt; Get the heading list chars from the first char to the first CR/LF and trim spaces&lt;/span&gt;
			&lt;span class="SQLKeyword"&gt;SET&lt;/span&gt; @Item &lt;span class="SQLOperator"&gt;=&lt;/span&gt; &lt;span class="SQLFunction"&gt;LTRIM&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;&lt;span class="SQLFunction"&gt;RTRIM&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;&lt;span class="SQLFunction"&gt;LEFT&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;@List&lt;span class="SQLOperator"&gt;,&lt;/span&gt; @Pos &lt;span class="SQLOperator"&gt;-&lt;/span&gt; 1&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt;

			&lt;span class="SQLComment"&gt;--&amp;lt; If the so calulated item is not empty...&lt;/span&gt;
			&lt;span class="SQLKeyword"&gt;IF&lt;/span&gt; @Item &lt;span class="SQLOperator"&gt;&amp;lt;&amp;gt;&lt;/span&gt; &lt;span class="SQLString"&gt;''&lt;/span&gt;
			&lt;span class="SQLKeyword"&gt;BEGIN&lt;/span&gt;
				&lt;span class="SQLComment"&gt;--&amp;lt; ...insert it in the @ParsedList temporary table&lt;/span&gt;
				&lt;span class="SQLKeyword"&gt;INSERT INTO&lt;/span&gt; @ParsedList &lt;span class="SQLOperator"&gt;(&lt;/span&gt;Item&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
				&lt;span class="SQLKeyword"&gt;VALUES&lt;/span&gt; &lt;span class="SQLOperator"&gt;(&lt;/span&gt;@Item&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
					&lt;span class="SQLComment"&gt;--(CAST(@Item AS int))	--&amp;lt; Use the appropriate conversion if needed&lt;/span&gt;
			&lt;span class="SQLKeyword"&gt;END&lt;/span&gt;

			&lt;span class="SQLComment"&gt;--&amp;lt; Remove the first item from the list...&lt;/span&gt;
			&lt;span class="SQLKeyword"&gt;SET&lt;/span&gt; @List &lt;span class="SQLOperator"&gt;=&lt;/span&gt; &lt;span class="SQLFunction"&gt;RIGHT&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;@List&lt;span class="SQLOperator"&gt;,&lt;/span&gt; &lt;span class="SQLFunction"&gt;LEN&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;@List&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLOperator"&gt;-&lt;/span&gt; @Pos &lt;span class="SQLOperator"&gt;-&lt;/span&gt; 1&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
			&lt;span class="SQLComment"&gt;--&amp;lt; ...and set the position to the next CR/LF&lt;/span&gt;
			&lt;span class="SQLKeyword"&gt;SET&lt;/span&gt; @Pos &lt;span class="SQLOperator"&gt;=&lt;/span&gt; &lt;span class="SQLFunction"&gt;CHARINDEX&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;&lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;13&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLOperator"&gt;+&lt;/span&gt; &lt;span class="SQLKeyword"&gt;CHAR&lt;/span&gt;&lt;span class="SQLOperator"&gt;(&lt;/span&gt;10&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;span class="SQLOperator"&gt;,&lt;/span&gt; @List&lt;span class="SQLOperator"&gt;,&lt;/span&gt; 1&lt;span class="SQLOperator"&gt;)&lt;/span&gt;
				&lt;span class="SQLComment"&gt;--&amp;lt; Repeat this block while the upon loop condition is verified&lt;/span&gt;
		&lt;span class="SQLKeyword"&gt;END&lt;/span&gt;
	&lt;span class="SQLKeyword"&gt;END&lt;/span&gt;

	&lt;span class="SQLKeyword"&gt;RETURN&lt;/span&gt;
&lt;span class="SQLKeyword"&gt;END&lt;/span&gt;&lt;/font&gt;&lt;/pre&gt;

&lt;p&gt;At this point, having created the UDF, our query is transformed trivially in:&lt;/p&gt;

&lt;pre class="SQLCode"&gt;&lt;span class="SQLKeyword"&gt;SELECT&lt;/span&gt; &lt;span class="SQLOperator"&gt;*&lt;/span&gt;
&lt;span class="SQLKeyword"&gt;FROM&lt;/span&gt; Sales&lt;span class="SQLOperator"&gt;.&lt;/span&gt;SalesOrderHeader &lt;span class="SQLKeyword"&gt;AS&lt;/span&gt; SOH
&lt;span class="SQLKeyword"&gt;WHERE&lt;/span&gt; SOH&lt;span class="SQLOperator"&gt;.&lt;/span&gt;SalesOrderNumber &lt;span class="SQLOperator"&gt;IN&lt;/span&gt; &lt;span class="SQLOperator"&gt;(&lt;/span&gt;
		&lt;span class="SQLKeyword"&gt;SELECT&lt;/span&gt; Item
		&lt;span class="SQLKeyword"&gt;FROM&lt;/span&gt; SplitCRLFList&lt;span class="SQLOperator"&gt;(&lt;/span&gt;&lt;span class="SQLString"&gt;'SO43667
SO43709
SO43726
SO43746
SO43782
SO43796'&lt;/span&gt;&lt;span class="SQLOperator"&gt;)&lt;/span&gt; &lt;span class="SQLKeyword"&gt;AS&lt;/span&gt; SCL&lt;span class="SQLOperator"&gt;)&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;Convenient, isn’t it? &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://weblogs.sqlteam.com/images/weblogs_sqlteam_com/lucaz/Windows-Live-Writer/Trasformare-in_14844/wlEmoticon-smile_2.png" /&gt;You can find the script DBA_SplitCRLFList.sql &lt;a href="http://sdrv.ms/N8bRs4"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Bye!!&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61421.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/0UwrqL0HCQU" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2012/06/12/how-to-use-a-list-of-values-in-excel-as-filter-in-a-query.aspx</guid>
            <pubDate>Tue, 12 Jun 2012 13:27:25 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2012/06/12/how-to-use-a-list-of-values-in-excel-as-filter-in-a-query.aspx#feedback</comments>
            <slash:comments>4</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61421.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61421.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2012/06/12/how-to-use-a-list-of-values-in-excel-as-filter-in-a-query.aspx</feedburner:origLink></item>
        <item>
            <title>How to update all the SSIS packages&amp;rsquo; Connection Managers in a BIDS project with PowerShell</title>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/Mw3LIUtwHrI/how-to-update-all-the-ssis-packagesrsquo-connection-managers-in.aspx</link>
            <description>&lt;p&gt;During the development of a BI solution, we all know that 80% of the time is spent during the ETL (Extract, Transform, Load) phase. If you use the BI Stack Tool provided by Microsoft SQL Server, this step is accomplished by the development of n Integration Services (SSIS) packages. In general, the number of packages made ​​in the ETL phase for a non-trivial solution of BI is quite significant.&lt;/p&gt;  &lt;p&gt;An SSIS package, therefore, extracts data from a source, it "hammers" :) the data and then transfers it to a specific destination. Very often it happens that the connection to the source data is the same for all packages. Using Integration Services, this results in having the same Connection Manager (perhaps with the same name) for all packages:&lt;/p&gt;  &lt;p&gt;&lt;img src="https://lh6.googleusercontent.com/-k7bF58-wFJI/T8abVIcruQI/AAAAAAAAAc8/clE4872LgUc/s145/ETL_01.png" /&gt;&lt;/p&gt;  &lt;p&gt;The source data of my BI solution comes from an Helper database (HLP), then, for each package tha import this data, I have the &lt;em&gt;HLP Connection Manager&lt;/em&gt; (the use of a &lt;em&gt;Shared Data Source &lt;/em&gt;is not recommended, because the Connection String is wired and therefore you have to open the SSIS project and use the proper wizard change it...). In order to change the HLP Connection String at runtime, we could use the &lt;em&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ms141682.aspx" target="_blank"&gt;Package Configuration&lt;/a&gt;&lt;/em&gt;, or we could run our packages with &lt;a href="http://dtloggedexec.davidemauri.it/" target="_blank"&gt;&lt;em&gt;DTLoggedExec&lt;/em&gt;&lt;/a&gt; by Davide Mauri (a must-have if you are developing with SQL Server 2005/2008). But my need was to change all the HLP connections in all packages &lt;strong&gt;within the SSIS Visual Studio project&lt;/strong&gt;, because I had to version them through &lt;em&gt;Team Foundation Server &lt;/em&gt;(TFS).&lt;/p&gt;  &lt;p&gt;A good scribe with a lot of patience should have changed by hand all the connections by double-clicking the HLP Connection Manager of each package, and then changing the referenced server/database:&lt;/p&gt;  &lt;p&gt;&lt;img src="https://lh5.googleusercontent.com/-trDV6ASreK4/T8abZS-pzoI/AAAAAAAAAdE/iIPhFHbR14k/s536/ETL_02.png" width="406" height="419" /&gt;&lt;/p&gt;  &lt;p&gt;Not being endowed with such virtues :) I took just a little of time to write a small script in PowerShell, using the fact that a SSIS package (a &lt;em&gt;.dtsx&lt;/em&gt; file) is nothing but an &lt;em&gt;xml&lt;/em&gt; file, and therefore can be changed quite easily. I'm not a guru of PowerShell, but I managed more or less to put together the following lines of code:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;em&gt;$LeftDelimiterString = "Initial Catalog="        &lt;br /&gt;$RightDelimiterString = ";Provider="         &lt;br /&gt;$ToBeReplacedString = "AstarteToBeReplaced"         &lt;br /&gt;$ReplacingString = "AstarteReplacing"         &lt;br /&gt;$MainFolder = "C:\MySSISPackagesFolder"&lt;/em&gt;&lt;/p&gt;    &lt;p&gt;&lt;em&gt;$files = &lt;b&gt;get-childitem&lt;/b&gt; "$MainFolder" *.dtsx &lt;/em&gt;&lt;em&gt;&lt;b&gt;`          &lt;br /&gt;&lt;/b&gt;      | &lt;b&gt;Where-Object&lt;/b&gt; {!($_.PSIsContainer)}&lt;/em&gt;&lt;/p&gt;    &lt;p&gt;&lt;em&gt;foreach ($file in $files)        &lt;br /&gt;{         &lt;br /&gt;      (&lt;b&gt;Get-Content&lt;/b&gt; $file.FullName) &lt;/em&gt;&lt;em&gt;&lt;b&gt;`          &lt;br /&gt;&lt;/b&gt;            | &lt;b&gt;%&lt;/b&gt; {$_ -replace "($LeftDelimiterString)($ToBeReplacedString)($RightDelimiterString)", "`$1$ReplacingString`$3"} &lt;/em&gt;&lt;em&gt;&lt;b&gt;`          &lt;br /&gt;&lt;/b&gt;| &lt;b&gt;Set-Content&lt;/b&gt; $file.FullName;         &lt;br /&gt;}&lt;/em&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;The script above just opens any SSIS package (&lt;em&gt;.dtsx&lt;/em&gt;) in the supplied folder, then for each of them goes in search of the following text:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;em&gt;Initial Catalog=AstarteToBeReplaced;Provider=&lt;/em&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;and it replaces the text found with this:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;em&gt;Initial Catalog=AstarteReplacing;Provider=&lt;/em&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;I don’t enter into the details of each cmdlet used. I leave the reader to search for these details.&lt;/p&gt;  &lt;p&gt;Alternatively, you can use a specific object model exposed in some .NET assemblies provided by Integration Services, or you can use the &lt;strong&gt;&lt;a href="http://www.codeplex.com/pacman" target="_blank"&gt;Pacman&lt;/a&gt;&lt;/strong&gt; utility:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://i.msdn.microsoft.com/dynimg/IC203350.jpg" /&gt;&lt;/p&gt;  &lt;p&gt;Enjoy! :)&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;P.S.&lt;/strong&gt; Using TFS as versioning system, before running the script I &lt;em&gt;checked out&lt;/em&gt; the packages and, after the script executed succesfully, I &lt;em&gt;checked in&lt;/em&gt; them.&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61417.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/Mw3LIUtwHrI" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2012/06/05/how-to-update-all-the-ssis-packagesrsquo-connection-managers-in.aspx</guid>
            <pubDate>Tue, 05 Jun 2012 10:16:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2012/06/05/how-to-update-all-the-ssis-packagesrsquo-connection-managers-in.aspx#feedback</comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61417.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61417.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2012/06/05/how-to-update-all-the-ssis-packagesrsquo-connection-managers-in.aspx</feedburner:origLink></item>
        <item>
            <title>BIDS Helper 1.6 Beta released!</title>
            <category>SSMS add-ons</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/hgG-F5rYIsA/bids-helper-1-6-beta-released.aspx</link>
            <description>&lt;p&gt;A new version of this fantastic tool, used by Microsoft BI Stack developers, is out. Now it’s compatible with SQL Server 2012.&lt;/p&gt;  &lt;p&gt;In this &lt;a href="http://prologika.com/CS/blogs/blog/archive/2012/03/20/bids-helper-1-6-beta-released.aspx" target="_blank"&gt;post&lt;/a&gt;, Teo Lachev gives us more details.&lt;/p&gt;  &lt;p&gt;This is the project’s &lt;a href="http://bidshelper.codeplex.com/" target="_blank"&gt;Home&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;Enjoy!&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61406.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/hgG-F5rYIsA" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2012/04/02/bids-helper-1-6-beta-released.aspx</guid>
            <pubDate>Mon, 02 Apr 2012 12:42:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2012/04/02/bids-helper-1-6-beta-released.aspx#feedback</comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61406.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61406.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2012/04/02/bids-helper-1-6-beta-released.aspx</feedburner:origLink></item>
        <item>
            <title>New release of &amp;quot;OLAP PivotTable Extensions&amp;quot;</title>
            <category>OLAP on Excel</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/30PcTd9rMsg/new-release-of-quotolap-pivottable-extensionsquot.aspx</link>
            <description>&lt;p&gt;For those who are not familiar with this add-in, the &lt;em&gt;OLAP PivotTable Extensions &lt;/em&gt;add features of interest to Excel 2007 or 2010 PivotTables pointing to an OLAP cube in Analysis Services. One of these features I like very much, is to know the MDX query code associated with the pivot used at that time in Excel:&lt;/p&gt;  &lt;p&gt;&lt;img alt="AvgTaxMDX2.png" src="http://i3.codeplex.com/Download?ProjectName=OlapPivotTableExtend&amp;amp;DownloadId=287708" /&gt;&lt;/p&gt;  &lt;p&gt;You can find all the details here:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://olappivottableextend.codeplex.com/"&gt;http://olappivottableextend.codeplex.com/&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;It was recently released a new version of the add-in (version 0.7.4), which does not introduce any new features, but fixes a significant bug:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;em&gt;Release 0.7.4 now properly handles languages but introduces no new features. International users who run a different Windows language than their Excel UI language may be receiving an error message when they double click a cell and perform drillthrough which reads: "&lt;/em&gt;&lt;a href="http://olappivottableextend.codeplex.com/workitem/22100"&gt;&lt;em&gt;XML for Analysis parser: The LocaleIdentifier property is not overwritable and cannot be assigned a new value&lt;/em&gt;&lt;/a&gt;&lt;em&gt;". This error was caused by OLAP PivotTable Extensions in some situations, but release 0.7.4 fixes this problem.&lt;/em&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Enjoy! &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://weblogs.sqlteam.com/images/weblogs_sqlteam_com/lucaz/Windows-Live-Writer/52fd7f98b01c_A4A4/wlEmoticon-smile_2.png" /&gt;&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61400.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/30PcTd9rMsg" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2012/02/06/new-release-of-quotolap-pivottable-extensionsquot.aspx</guid>
            <pubDate>Mon, 06 Feb 2012 11:20:16 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2012/02/06/new-release-of-quotolap-pivottable-extensionsquot.aspx#feedback</comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61400.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61400.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2012/02/06/new-release-of-quotolap-pivottable-extensionsquot.aspx</feedburner:origLink></item>
        <item>
            <title>How to import in BIDS more than one SSIS package in one shot!</title>
            <category>SSIS</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/QpIJaz-uCJ8/how-to-import-in-bids-more-than-one-ssis-package.aspx</link>
            <description>&lt;p&gt;Have you ever wanted to add more than one Integration Services existing package (e.g. 20 packages) in a SSIS project? Well, you may suppose that an Open Dialog supports multiple files selection to import more than one file at a time ...&lt;/p&gt;  &lt;p&gt;&lt;img src="https://lh3.googleusercontent.com/-HMFgzKOGxAE/TyavDLPAKhI/AAAAAAAAAYw/fxGGgQd5-xw/s640/AddSSISPackages_01.png" /&gt;&lt;/p&gt;  &lt;p&gt;BIDS Open Dialog doesn’t allow this, you can just select a single file! Hence the loss of valuable time spent to import the packages one at a time.&lt;/p&gt;  &lt;p&gt;Few days ago I learned a trick that solves the problem, thanks to &lt;a href="http://www.mattmasson.com/index.php/2012/01/ssis-quick-tip-copy-paste-packages-into-a-visual-studio-project/?utm_source=rss&amp;amp;utm_medium=rss&amp;amp;utm_campaign=ssis-quick-tip-copy-paste-packages-into-a-visual-studio-project" target="_blank"&gt;this post&lt;/a&gt; by &lt;strong&gt;Matt Masson&lt;/strong&gt;.&lt;/p&gt;  &lt;p&gt;Just copy all the packages to import from Windows Explorer (Ctrl + C):&lt;/p&gt;  &lt;p&gt;&lt;img style="margin: 0px 5px" src="https://lh4.googleusercontent.com/-zp3p_UGYHnI/TyavvOJNezI/AAAAAAAAAY8/n5mw-d8_Cs0/s837/AddSSISPackages_02.png" width="538" height="271" /&gt;&lt;/p&gt;  &lt;p&gt;Then just right click on the &lt;em&gt;SSIS Packages &lt;/em&gt;folder of the Integration Services project and make a simple &lt;em&gt;Past&lt;/em&gt; (CTRL + V):&lt;/p&gt;  &lt;p&gt;&lt;img src="https://lh3.googleusercontent.com/-WPXNDXCpf8E/Tya0UDwANqI/AAAAAAAAAZo/JPFQcd-xsTE/s341/AddSSISPackages_03.png" /&gt;&lt;/p&gt;  &lt;p&gt;So “auto-magically” you’ll have all those packages imported in your Integration Services project!!&lt;/p&gt;  &lt;p&gt;&lt;img src="https://lh6.googleusercontent.com/-NklM9wqE2Bo/Tya0UFY_chI/AAAAAAAAAZs/qcRZpWnl4do/s702/AddSSISPackages_04.png" /&gt;&lt;/p&gt;  &lt;p&gt;What can I say... this feature was well hidden! &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://weblogs.sqlteam.com/images/weblogs_sqlteam_com/lucaz/Windows-Live-Writer/ba1d7af04778_CFA3/wlEmoticon-smile_2.png" /&gt;&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61399.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/QpIJaz-uCJ8" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2012/02/02/how-to-import-in-bids-more-than-one-ssis-package.aspx</guid>
            <pubDate>Thu, 02 Feb 2012 20:27:14 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2012/02/02/how-to-import-in-bids-more-than-one-ssis-package.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61399.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61399.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2012/02/02/how-to-import-in-bids-more-than-one-ssis-package.aspx</feedburner:origLink></item>
        <item>
            <title>Let&amp;rsquo;s keep informed with &amp;ldquo;Data Explorer&amp;rdquo;</title>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/cjC3Z41c4v4/letrsquos-keep-informed-with-ldquodata-explorerrdquo.aspx</link>
            <description>&lt;p&gt;At Pass Summit 2011 a new project was announced. It’s a &lt;em&gt;Microsoft SQL Azure Lab&lt;/em&gt; and its codename is &lt;strong&gt;Microsoft “Data Explorer”&lt;/strong&gt;. According to the official blog (&lt;a href="http://blogs.msdn.com/b/dataexplorer/"&gt;http://blogs.msdn.com/b/dataexplorer/&lt;/a&gt;), this new tool provides an innovative way to acquire new knowledge from the data that interest you. In a nutshell, &lt;em&gt;Data Explorer&lt;/em&gt; allows you to combine data from multiple sources, to publish and share the result. In addition, you can generate data streams in the &lt;em&gt;RESTful&lt;/em&gt; open format (&lt;a href="http://www.odata.org/" target="_blank"&gt;Open Data Protocol&lt;/a&gt;), and they can then be used by other applications. Nonetheless we can still use Excel or PowerPivot to analyze the results.&lt;/p&gt;  &lt;p&gt;Sources can be varied: Excel spreadsheets, text files, databases, &lt;strong&gt;Windows Azure Marketplace&lt;/strong&gt;, etc.. For those who are not familiar with this resource, I strongly suggest you to keep an eye on the data services available to the Marketplace:&lt;/p&gt;  &lt;p&gt;&lt;a href="https://datamarket.azure.com/browse/Data"&gt;https://datamarket.azure.com/browse/Data&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;To tell the truth, as I read the above blog post, I was tempted to think of the &lt;em&gt;Data Explorer&lt;/em&gt; as a "SSIS on Azure" addressed to the Power User. In fact, reading the response from Tim Mallalieu (Group Program Manager of &lt;em&gt;Data Explorer&lt;/em&gt;) to the comment made to his &lt;a href="http://blogs.msdn.com/b/timmall/archive/2011/10/17/early-walkthrough-of-the-montego-client.aspx" target="_blank"&gt;post&lt;/a&gt;, I had a positive response to my first impression:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;“…we originally thinking of ourselves as Self-Service ETL. As we talked to more folks and started partnering with other teams we realized that would be an area that we can add value but that there were more opportunities emerging.”&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;The typical operations of the ETL phase ( processing and organization of data in different formats) can be obtained thanks to &lt;a href="http://blogs.msdn.com/b/dataexplorer/archive/2011/10/26/data-explorer-mashup-101.aspx" target="_blank"&gt;Data Explorer Mashup&lt;/a&gt;. This is an image of the tool:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://blogs.msdn.com/cfs-filesystemfile.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-48-46-metablogapi/7450.image_5F00_4D853984.png" width="529" height="225" /&gt;&lt;/p&gt;  &lt;p&gt;The flexibility in the manipulation of information is given by &lt;em&gt;&lt;a href="http://blogs.msdn.com/b/dataexplorer/archive/2011/11/17/the-data-explorer-formula-language.aspx" target="_blank"&gt;Data Explorer Formula Language&lt;/a&gt;&lt;/em&gt;. This is a formula-based Excel-style specific language:&lt;/p&gt;  &lt;p&gt;&lt;img src="http://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-48-46-Formula+Language+Series-Post+1/7024.7.png" /&gt;&lt;/p&gt;  &lt;p&gt;Anyone wishing to know more can check the project page in addition to aforementioned blog:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.microsoft.com/en-us/sqlazurelabs/labs/dataexplorer.aspx"&gt;http://www.microsoft.com/en-us/sqlazurelabs/labs/dataexplorer.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;In light of this new project, there is no doubt about the intention of Microsoft to get closer and closer to the Power User, providing him flexible and very easy to use tools for data analysis. The prime example of this is &lt;em&gt;PowerPivot&lt;/em&gt;.&lt;/p&gt;  &lt;p&gt;The question that remains is always the same: having in a company more Power User will implicitly mean having different data models representing the same reality. But this would inevitably lead to anarchical data management... What do you think about that?&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61392.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/cjC3Z41c4v4" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2011/12/10/letrsquos-keep-informed-with-ldquodata-explorerrdquo.aspx</guid>
            <pubDate>Sat, 10 Dec 2011 12:39:20 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2011/12/10/letrsquos-keep-informed-with-ldquodata-explorerrdquo.aspx#feedback</comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61392.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61392.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2011/12/10/letrsquos-keep-informed-with-ldquodata-explorerrdquo.aspx</feedburner:origLink></item>
        <item>
            <title>A new version of SQL Treeo released</title>
            <category>SSMS</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/XSx6K-888_s/versione-2-di-sql-treeo-rilasciata.aspx</link>
            <description>&lt;p&gt;A new SQL Treeo update is available at &lt;a href="http://www.sqltreeo.com"&gt;http://www.sqltreeo.com&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;Lot of bugs fixed so now it seems to be a stable add-on for SSMS.&lt;/p&gt;  &lt;p&gt;The full change log is available here:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.sqltreeo.com/wp/new-version-of-sql-treeo-ssms-productivity-add-in-was-released/"&gt;http://www.sqltreeo.com/wp/new-version-of-sql-treeo-ssms-productivity-add-in-was-released/&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;So, update your SSMS clients :)&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61386.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/XSx6K-888_s" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2011/11/09/versione-2-di-sql-treeo-rilasciata.aspx</guid>
            <pubDate>Wed, 09 Nov 2011 08:34:40 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2011/11/09/versione-2-di-sql-treeo-rilasciata.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61386.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61386.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2011/11/09/versione-2-di-sql-treeo-rilasciata.aspx</feedburner:origLink></item>
        <item>
            <title>Running your SSMS client as a domain user even if you&amp;rsquo;re not in a domain</title>
            <category>SSMS</category>
            <category>SSMS add-ons</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/MvThITh9HhY/running-your-ssms-client-as-a-domain-user.aspx</link>
            <description>&lt;p&gt;I wonder if it is possible to use the SQL Server Management Studio (SSMS) client on my machine with a specific domain user when my machine wasn’t in that domain. In fact, many developers use some SSMS add-ons installed on their machine (with appropriate licenses), which greatly simplify their daily work.&lt;/p&gt;  &lt;p&gt;For example, I’m a &lt;em&gt;Red Gate SQL Prompt&lt;/em&gt; addicted &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://weblogs.sqlteam.com/images/weblogs_sqlteam_com/lucaz/Windows-Live-Writer/7edca5031ba6_11F39/wlEmoticon-smile_2.png" /&gt;, so it’d be convenient for me to work on customers’ SQL Server instances with this tool. After reading Davide Mauri’s &lt;a href="http://sqlblog.com/blogs/davide_mauri/archive/2011/08/18/running-and-application-with-a-domain-user-even-if-you-re-not-in-a-domain.aspx" target="_blank"&gt;post&lt;/a&gt;, a friend and collegue of mine, I created a batch file in order to specify a domain and a user for SSMS:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;font face="Courier New"&gt;@echo off       &lt;br /&gt;echo ***************************************        &lt;br /&gt;echo *** Run SSMS 2008 R2 as domain user ***        &lt;br /&gt;echo ***************************************        &lt;br /&gt;echo.&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;font face="Courier New"&gt;set /P user="Type the domain\username: "&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;font face="Courier New"&gt;C:\Windows\System32\runas.exe /netonly /user:%user% "C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\Ssms.exe"&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Then, you can create on your desktop a shortcut to the file batch previously developed and you can also change the shortcut icon, using the same SSMS icon (get it from the &lt;font face="Courier New"&gt;Ssms.exe&lt;/font&gt; file). Now if you double-click on the shortcut, you can set domain and user for the SSMS client &lt;em&gt;on-the-fly&lt;/em&gt;:&lt;/p&gt;  &lt;p&gt;&lt;img alt="" src="http://img692.imageshack.us/img692/6488/image000tbq.png" /&gt;&lt;/p&gt;  &lt;p&gt;So enjoy using your “personal” SSMS client on your preferred domain &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://weblogs.sqlteam.com/images/weblogs_sqlteam_com/lucaz/Windows-Live-Writer/7edca5031ba6_11F39/wlEmoticon-smile_2.png" /&gt;&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61342.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/MvThITh9HhY" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2011/08/29/running-your-ssms-client-as-a-domain-user.aspx</guid>
            <pubDate>Mon, 29 Aug 2011 20:46:58 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2011/08/29/running-your-ssms-client-as-a-domain-user.aspx#feedback</comments>
            <slash:comments>11</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61342.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61342.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2011/08/29/running-your-ssms-client-as-a-domain-user.aspx</feedburner:origLink></item>
        <item>
            <title>Custom Folders in SSMS Object Explorer? Yes, we can!</title>
            <category>SSMS</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/yYQmydutyMc/custom-folders-in-ssms-object-explorer-yes-we-can.aspx</link>
            <description>&lt;p&gt;When you have a huge objects’ number in SSMS Object Explorer, you often get lost in finding items. So it’d be useful to catalog those objects in folders, in order to follow an application’s logical layer subdivision, for example.&lt;/p&gt;  &lt;p&gt;There is a fantastic add-in for SSMS that helps us to do that:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.sqltreeo.com/"&gt;http://www.sqltreeo.com&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;The developer of this add-in has written a related post in his blog:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.sqltreeo.com/wp/dowload-free-ssms-add-in-to-create-own-folder-for-database-objects/"&gt;http://www.sqltreeo.com/wp/dowload-free-ssms-add-in-to-create-own-folder-for-database-objects/&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;So another useful tool to add to our  SQL Server toolbox &lt;img alt="Winking smile" src="http://community.ugiss.org/blogs/lucazav/wlEmoticon-winkingsmile_172498CB.png" /&gt;&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61341.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/yYQmydutyMc" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2011/08/28/custom-folders-in-ssms-object-explorer-yes-we-can.aspx</guid>
            <pubDate>Sun, 28 Aug 2011 15:09:14 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2011/08/28/custom-folders-in-ssms-object-explorer-yes-we-can.aspx#feedback</comments>
            <slash:comments>2</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61341.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61341.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2011/08/28/custom-folders-in-ssms-object-explorer-yes-we-can.aspx</feedburner:origLink></item>
        <item>
            <title>Online Introduction to Relational Databases (and not only) with Stanford University!</title>
            <category>database theory</category>
            <link>http://feedproxy.google.com/~r/TheSqlServerSideOfMeen-us/~3/XiWL8dzBF_8/online-introduction-to-relational-databases-with-stanford-university.aspx</link>
            <description>&lt;p&gt;How many of you know exactly the definition of "relational database"? What exactly the adjective "relational" refers to? Many of you allow themselves to be deceived, thinking this adjective is related to foreign key constraints between tables. Instead this adjective lurks in a world based on set theory, relational algebra and the concept of relationship intended as a table.&lt;/p&gt;&lt;p&gt;Well, for those who want to deep the fundamentals of relational model, relational algebra, XML, OLAP and emerging "NoSQL" systems, Stanford University School of Engineering offers a public and free online introductory course to databases.&lt;/p&gt;  &lt;p&gt;This is the related web page:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.db-class.com/"&gt;http://www.db-class.com/&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;The course will last 2 months, after which there will be a final exam. Passing the final exam will entitle the participants to receive a statement of accomplishment.&lt;/p&gt;  &lt;p&gt;A syllabus and more information is available &lt;a href="http://infolab.stanford.edu/~widom/cs145/index.html"&gt;here&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;Happy eLearning to you! &lt;img alt="Smile" src="http://community.ugiss.org/blogs/lucazav/wlEmoticon-smile_077298F0.png" /&gt;&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/lucaz/aggbug/61339.aspx" width="1" height="1" /&gt;&lt;img src="http://feeds.feedburner.com/~r/TheSqlServerSideOfMeen-us/~4/XiWL8dzBF_8" height="1" width="1"/&gt;</description>
            <dc:creator>Luca Zavarella</dc:creator>
            <guid isPermaLink="false">http://weblogs.sqlteam.com/lucaz/archive/2011/08/20/online-introduction-to-relational-databases-with-stanford-university.aspx</guid>
            <pubDate>Sat, 20 Aug 2011 13:05:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/lucaz/archive/2011/08/20/online-introduction-to-relational-databases-with-stanford-university.aspx#feedback</comments>
            <slash:comments>3</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/lucaz/comments/commentRss/61339.aspx</wfw:commentRss>
            <trackback:ping>http://weblogs.sqlteam.com/lucaz/services/trackbacks/61339.aspx</trackback:ping>
        <feedburner:origLink>http://weblogs.sqlteam.com/lucaz/archive/2011/08/20/online-introduction-to-relational-databases-with-stanford-university.aspx</feedburner:origLink></item>
    </channel>
</rss>
