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

<channel>
	<title>SSIS Talk</title>
	<atom:link href="http://www.ssistalk.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ssistalk.com</link>
	<description>Random thoughts and experiences with SSIS, by Phil Brammer</description>
	<lastBuildDate>Thu, 22 Mar 2012 00:31:11 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Connecting to a pre-SQL 2012 SSIS Instance with SQL 2012 SSMS</title>
		<link>http://www.ssistalk.com/2012/03/21/connecting-to-a-pre-sql-2012-ssis-instance-with-sql-2012-ssms/</link>
		<comments>http://www.ssistalk.com/2012/03/21/connecting-to-a-pre-sql-2012-ssis-instance-with-sql-2012-ssms/#comments</comments>
		<pubDate>Thu, 22 Mar 2012 00:31:11 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[SQL Server 2005]]></category>
		<category><![CDATA[SQL Server 2008]]></category>
		<category><![CDATA[SQL Server 2012]]></category>
		<category><![CDATA[SSIS]]></category>
		<category><![CDATA[SSIS Connectivity]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=306</guid>
		<description><![CDATA[If you are using SQL Server Management Studio in SQL 2012 to try to connect to an older SSIS instance (SQL 2008 R2 and earlier) called &#8220;SSISServerName&#8221;, you will get an error:

Connecting to the Integration Services service on the computer &#8220;SSISServerName&#8221; failed with the following error: &#8220;Class not registered&#8221;.
This error can occur when you try [...]]]></description>
			<content:encoded><![CDATA[<p>If you are using SQL Server Management Studio in SQL 2012 to try to connect to an older SSIS instance (SQL 2008 R2 and earlier) called &#8220;SSISServerName&#8221;, you will get an error:</p>
<blockquote><p>
Connecting to the Integration Services service on the computer &#8220;SSISServerName&#8221; failed with the following error: &#8220;Class not registered&#8221;.</p>
<p>This error can occur when you try to connect to a SQL Server 2005 Integration Services service from the current version of the SQL Server tools. Instead, add folders to the service configuration file to let the local Integration Services service manage packages on the SQL Server 2005 instance.
</p></blockquote>
<p>Not to worry, there is a workaround.  It&#8217;s not the most logical workaround, but it will work.  The SSIS service has a concept of &#8220;folders.&#8221;  Read on for more details.<br />
<span id="more-306"></span><br />
  You see them when you connect to an SSIS instance through SSMS:<br />
<img src="http://www.ssistalk.com/ssis_ssmsfolders.png" alt="SSMS Folders for the SSIS Service" /></p>
<p>We can add additional folders that connect to remote instances (yes, even pre-SQL 2012 instances) by editing the MsDtsSrvr.ini.xml file on a SQL 2012 instance (perhaps your local machine) and restarting the SSIS service on the same machine.  Here&#8217;s how.</p>
<ul>
<li>Open the MsDtsSrvr.ini.xml file.  It is typically located in C:\Program Files\Microsoft SQL Server\110\DTS\Binn\MsDtsSrvr.ini.xml.</li>
<li>Add a folder to the TopLevelFolders node.  This folder should be configured to point to your remote non-SQL 2012 SSIS instance.</li>
<li>Restart the SSIS service.</li>
</ul>
<p>An example XML file that adds a new folder that points to the named SQL instance, MyServer\SQL01 will look like:<br />
<code>
<pre>
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;DtsServiceConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;
   &lt;StopExecutingPackagesOnShutdown&gt;true&lt;/StopExecutingPackagesOnShutdown&gt;
   &lt;TopLevelFolders&gt;
      &lt;Folder xsi:type="SqlServerFolder"&gt;
         &lt;Name&gt;MSDB&lt;/Name&gt;
         &lt;ServerName&gt;.\SQL2012&lt;/ServerName&gt;
      &lt;/Folder&gt;
      &lt;Folder xsi:type="FileSystemFolder"&gt;
         &lt;Name&gt;File System&lt;/Name&gt;
         &lt;StorePath&gt;..\Packages&lt;/StorePath&gt;
      &lt;/Folder&gt;
      <B>&lt;Folder xsi:type="SqlServerFolder"&gt;
         &lt;Name&gt;MyServerFolder&lt;/Name&gt;
         &lt;ServerName&gt;MyServer\SQL01&lt;/ServerName&gt;
      &lt;/Folder&gt;</B>
   &lt;/TopLevelFolders&gt;
&lt;/DtsServiceConfiguration&gt;
</pre>
<p></code></p>
<p>Once the folder entry for &#8220;MyServerFolder&#8221; has been added, save the file, and then restart the SSIS Service via the Services Control Panel or via the SQL Server Configuration Manager.  </p>
<p><img src="http://www.ssistalk.com/ssis_ssmsfolders_restartSSIS.png" alt="Restart via SQL Server Configuration Manager" /></p>
<p>Then connect to your local SSIS service in SSMS to see the new folder.  It should look as so:</p>
<p><img src="http://www.ssistalk.com/ssis_ssmsfolders_additionalfolder.png" alt="Additional folder added." /></p>
<p>Let me know if you have any additional questions.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2012/03/21/connecting-to-a-pre-sql-2012-ssis-instance-with-sql-2012-ssms/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Free SQL Server 2012 eBook from Microsoft Press</title>
		<link>http://www.ssistalk.com/2012/03/19/free-sql-server-2012-ebook-from-microsoft-press/</link>
		<comments>http://www.ssistalk.com/2012/03/19/free-sql-server-2012-ebook-from-microsoft-press/#comments</comments>
		<pubDate>Tue, 20 Mar 2012 00:36:44 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[SQL Server 2012]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/2012/03/19/free-sql-server-2012-ebook-from-microsoft-press/</guid>
		<description><![CDATA[Get your free Microsoft Press eBook, Introducing Microsoft SQL Server 2012 by visiting this link to get your PDF version today &#8211; http://blogs.msdn.com/b/microsoft_press/archive/2012/03/15/free-ebook-introducing-microsoft-sql-server-2012.aspx
This book was written by former MVP turned Microsoft employee Ross Mistry and current MVP Stacia Misner.  Enjoy!
]]></description>
			<content:encoded><![CDATA[<p>Get your free Microsoft Press eBook, <em>Introducing Microsoft SQL Server 2012</em> by visiting this link to get your PDF version today &#8211; <a href="http://blogs.msdn.com/b/microsoft_press/archive/2012/03/15/free-ebook-introducing-microsoft-sql-server-2012.aspx">http://blogs.msdn.com/b/microsoft_press/archive/2012/03/15/free-ebook-introducing-microsoft-sql-server-2012.aspx</a></p>
<p>This book was written by former MVP turned Microsoft employee Ross Mistry and current MVP Stacia Misner.  Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2012/03/19/free-sql-server-2012-ebook-from-microsoft-press/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Which SQL Client versions are connecting to my instance?</title>
		<link>http://www.ssistalk.com/2012/02/17/which-sql-client-versions-are-connecting-to-my-instance/</link>
		<comments>http://www.ssistalk.com/2012/02/17/which-sql-client-versions-are-connecting-to-my-instance/#comments</comments>
		<pubDate>Fri, 17 Feb 2012 14:02:17 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Server 2005]]></category>
		<category><![CDATA[SQL Server 2008]]></category>
		<category><![CDATA[SQL Server 2012]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=290</guid>
		<description><![CDATA[Without fully restating what&#8217;s already published, please read this MSDN Blog Post for more details on how to determine which SQL Client version is connecting to a SQL instance.
Basically, 
SELECT CAST(protocol_version as BINARY(4))  FROM sys.dm_exec_connections
 will tell you which version is connecting to your instance based on the TDS protocol appendix document, http://msdn.microsoft.com/en-us/library/dd339982(PROT.13).aspx.
SQL Server [...]]]></description>
			<content:encoded><![CDATA[<p>Without fully restating what&#8217;s already published, please read this <a href="http://blogs.msdn.com/b/sqlcat/archive/2010/10/26/how-to-tell-which-version-of-sql-server-data-access-driver-is-used-by-an-application-client.aspx">MSDN Blog Post</a> for more details on how to determine which SQL Client version is connecting to a SQL instance.</p>
<p>Basically, <code><br />
SELECT CAST(protocol_version as BINARY(4))<BR>  FROM <a href="http://msdn.microsoft.com/en-us/library/ms181509.aspx">sys.dm_exec_connections</a><br />
</code> will tell you which version is connecting to your instance based on the TDS protocol appendix document, <a href="http://msdn.microsoft.com/en-us/library/dd339982(PROT.13).aspx">http://msdn.microsoft.com/en-us/library/dd339982(PROT.13).aspx</a>.</p>
<p>SQL Server 2012 is almost complete, and we now know that the TDS protocol version for this will be 0&#215;74000004.  </p>
<p>Another option appears to be to use the client_version column in <a href="http://msdn.microsoft.com/en-us/library/ms176013.aspx">sys.dm_exec_sessions</a>.  A client_version = 4 is SQL Server 2000.  5 = SQL Server 2005.  6 = SQL Server 2008.  7 = SQL Server 2012.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2012/02/17/which-sql-client-versions-are-connecting-to-my-instance/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Omaha SSUG Meeting Tonight &#8211; Feb 1st, 2012</title>
		<link>http://www.ssistalk.com/2012/02/01/omaha-ssug-meeting-tonight-feb-1st-2012/</link>
		<comments>http://www.ssistalk.com/2012/02/01/omaha-ssug-meeting-tonight-feb-1st-2012/#comments</comments>
		<pubDate>Wed, 01 Feb 2012 12:48:29 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[SQL Server]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=288</guid>
		<description><![CDATA[Tonight is the first 2012 SSUG meeting for the Omaha area.  The agenda for tonight is simply to have an open discussion on any topics you want to bring up &#8211; a current SQL issue you&#8217;re working on, upgrade problems, architecture questions, etc&#8230;  I will be in attendance helping with the discussion.
Please register [...]]]></description>
			<content:encoded><![CDATA[<p>Tonight is the first 2012 SSUG meeting for the Omaha area.  The agenda for tonight is simply to have an open discussion on any topics you want to bring up &#8211; a current SQL issue you&#8217;re working on, upgrade problems, architecture questions, etc&#8230;  I will be in attendance helping with the discussion.</p>
<p>Please register if you plan on attending so that the hosts can arrange enough food as well as to ensure you get registered for SWAG!</p>
<p><a href="http://omahamtg.com/Events.aspx?ID=142">http://omahamtg.com/Events.aspx?ID=142</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2012/02/01/omaha-ssug-meeting-tonight-feb-1st-2012/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SSIS 2012 &#8211; SSIS Environment Variables String Limit</title>
		<link>http://www.ssistalk.com/2012/01/17/ssis-2012-ssis-environment-variables-string-limit/</link>
		<comments>http://www.ssistalk.com/2012/01/17/ssis-2012-ssis-environment-variables-string-limit/#comments</comments>
		<pubDate>Tue, 17 Jan 2012 23:26:19 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[SQL Server 2012]]></category>
		<category><![CDATA[SSIS]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=283</guid>
		<description><![CDATA[UPDATE: 2012-02-24 &#8211; The bug I submitted on this has been closed as &#8220;won&#8217;t fix.&#8221;  I had asked the team to enforce this limitation in the GUI instead of throwing a somewhat cryptic error.  Sorry.
When creating environments in the new SSIS catalog, you are able to define environment variables.  When creating string [...]]]></description>
			<content:encoded><![CDATA[<p>UPDATE: 2012-02-24 &#8211; The bug I submitted on this has been closed as &#8220;won&#8217;t fix.&#8221;  I had asked the team to enforce this limitation in the GUI instead of throwing a somewhat cryptic error.  Sorry.</p>
<p>When creating environments in the new SSIS catalog, you are able to define environment variables.  When creating string variables, you are limited to a string length of 4,000 characters.  If you exceed 4,000 characters, you will receive an error.  Details below.</p>
<p>Environment variables can be created by right-clicking on the environment in question and selecting &#8220;Properties.&#8221;<br />
<img src="http://www.ssistalk.com/ssis_environment_var01.png" alt="SSIS Environment Properties" /></p>
<p>In the properties window, select &#8220;Variables&#8221; so that you can add new variables.<br />
<img src="http://www.ssistalk.com/ssis_environment_var02.png" alt="SSIS Environment Variable Properties Window" /></p>
<p>As long as you stay within the 4,000 character limit, you&#8217;ll be fine.  If you exceed that limit, expect an error message as below:<br />
<img src="http://www.ssistalk.com/ssis_environment_var03.png" alt="SSIS Environment Variables String Error" /></p>
<p>Clicking on the error message in the highlighted progress window, you can see the full details:<br />
<img src="http://www.ssistalk.com/ssis_environment_var04.png" alt="SSIS Environment Variables String Error Detail" /></p>
<p>Yep, internally, the SSIS team uses the sql_variant data type, which cannot store an NVARCHAR(MAX) column.  Since our string is longer than 4,000 characters (the max limit for NVARCHAR), the data type of the data we are sending must be converted to an NVARCHAR(MAX) which is an incompatible type for sql_variant.</p>
<p>The SSIS team is aware of this and hopefully they&#8217;ll be putting in a limit to prevent users from entering anything more than 4,000 characters to prevent the error from happening in the first place, or at least raising awareness of the limitation.</p>
<p>Also of a somewhat unrelated note &#8211; if you choose to set a variable to &#8220;sensitive&#8221; once you save it to the database by clicking the OK button, you will not be able to retrieve its value from within the GUI.  Just beware.  Treat the sensitive property as if you were working with passwords (which may be a common use of this property anyhow).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2012/01/17/ssis-2012-ssis-environment-variables-string-limit/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Off Topic: Copy masters between projects in Apple Aperture 3</title>
		<link>http://www.ssistalk.com/2011/09/23/off-topic-copy-masters-between-projects-in-apple-aperture-3/</link>
		<comments>http://www.ssistalk.com/2011/09/23/off-topic-copy-masters-between-projects-in-apple-aperture-3/#comments</comments>
		<pubDate>Fri, 23 Sep 2011 23:30:44 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[Off Topic]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=281</guid>
		<description><![CDATA[I&#8217;ve found very little reference online about how to copy a master image from one Aperture project to another.  The solution is quite simple &#8211; hold down the Option key while dragging an image from one project to another.  That&#8217;s it.
]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve found very little reference online about how to copy a master image from one Aperture project to another.  The solution is quite simple &#8211; hold down the Option key while dragging an image from one project to another.  That&#8217;s it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2011/09/23/off-topic-copy-masters-between-projects-in-apple-aperture-3/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SQL Saturday #91: Omaha &#8211; I will be presenting</title>
		<link>http://www.ssistalk.com/2011/08/04/sql-saturday-91-omaha-i-will-be-presenting/</link>
		<comments>http://www.ssistalk.com/2011/08/04/sql-saturday-91-omaha-i-will-be-presenting/#comments</comments>
		<pubDate>Thu, 04 Aug 2011 13:19:58 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[SQL Server]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=278</guid>
		<description><![CDATA[Saturday, August 27th, in Omaha, NE, we are hosting a SQL Saturday event that is promising to be a great time.  This is a free event ($10 lunch fee if you want lunch on us) that helps promote our local SQL PASS chapter.  Register here: http://www.sqlsaturday.com/91/eventhome.aspx
I will be presenting on two topics: SSIS [...]]]></description>
			<content:encoded><![CDATA[<p>Saturday, August 27th, in Omaha, NE, we are hosting a <a href="http://www.sqlsaturday.com">SQL Saturday</a> event that is promising to be a great time.  This is a free event ($10 lunch fee if you want lunch on us) that helps promote our local SQL PASS chapter.  Register here: <a href="http://www.sqlsaturday.com/91/eventhome.aspx">http://www.sqlsaturday.com/91/eventhome.aspx</a></p>
<p>I will be presenting on two topics: SSIS changes in Denali, and Using Event Notifications for Monitoring SQL Instances.  </p>
<p>The first session, SSIS Changes in Denali, is pretty self-explanatory.  Expect that I will go through each of the major changes in demo form, with some discussions around each.</p>
<p>The second session around Event Notifications, will be quite a bit more advanced and will talk about using the Event Notifications infrastructure in SQL Server combined with Service Broker to implement a very robust monitoring system.  This infrastructure allows for capturing all kinds of audit information such as creating a table, dropping an index, rebuilding statistics, blocking, deadlocks, etc&#8230;  There&#8217;s quite a bit of information that can be captured.  I will show how to set this up and how to consume the information for monitoring purposes.  </p>
<p>Don&#8217;t miss your chance at seeing me speak (!) and most importantly don&#8217;t miss your chance at learning SQL Server topics for free.  See you there!</p>
<p>An event flyer can be found here: <a href="http://www.ssistalk.com/Flyer_updated.pdf">http://www.ssistalk.com/Flyer_updated.pdf</a>  Please distribute as you see fit!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2011/08/04/sql-saturday-91-omaha-i-will-be-presenting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SQLSaturday #91 &#8211; Call for speakers (attendees too!)</title>
		<link>http://www.ssistalk.com/2011/07/12/sqlsaturday-91-call-for-speakers-attendees-too/</link>
		<comments>http://www.ssistalk.com/2011/07/12/sqlsaturday-91-call-for-speakers-attendees-too/#comments</comments>
		<pubDate>Tue, 12 Jul 2011 20:02:14 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=275</guid>
		<description><![CDATA[Omaha, Nebraska.  A town based alongside the Great Flood of 2011 Part II (The Missouri River) will be hosting its first SQLSaturday event on August 27th, 2011.  A SQL PASS sponsored event offering a full day of free SQL Server education, networking, food, and fun.  The event will be held at the [...]]]></description>
			<content:encoded><![CDATA[<p>Omaha, Nebraska.  A town based alongside the Great Flood of 2011 Part II (The Missouri River) will be hosting its first SQLSaturday event on August 27th, 2011.  A SQL PASS sponsored event offering a full day of free SQL Server education, networking, food, and fun.  The event will be held at the brand new, state of the art College of Business Administration building at the University of Nebraska at Omaha&#8217;s campus. </p>
<p>We have the call for speakers open right now.  If you would like to speak and would like to know more information, please contact me (using the Contact link at the top of the page) or submit your details online and let us know you&#8217;d like some more information. </p>
<p>For more details, visit <a href="http://www.sqlsaturday.com/91/eventhome.aspx">http://www.sqlsaturday.com/91/eventhome.aspx</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2011/07/12/sqlsaturday-91-call-for-speakers-attendees-too/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SQL Server &#8220;Denali&#8221; CTP 3 Released</title>
		<link>http://www.ssistalk.com/2011/07/12/sql-server-denali-ctp-3-released/</link>
		<comments>http://www.ssistalk.com/2011/07/12/sql-server-denali-ctp-3-released/#comments</comments>
		<pubDate>Tue, 12 Jul 2011 19:55:36 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[SQL Server "Denali"]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=273</guid>
		<description><![CDATA[After much waiting, what is perhaps the most complete release to-date of the next version of SQL Server, code named &#8220;Denali&#8221; has been released.  This is Community Technology Preview #3 (CTP 3) and will be well worth your time to experiment with.  If you&#8217;ve worked with CTP 1, throw it away and move [...]]]></description>
			<content:encoded><![CDATA[<p>After much waiting, what is perhaps the most complete release to-date of the next version of SQL Server, code named &#8220;Denali&#8221; has been released.  This is Community Technology Preview #3 (CTP 3) and will be well worth your time to experiment with.  If you&#8217;ve worked with CTP 1, throw it away and move toward CTP 3.  It should pretty much contain all of the features you&#8217;ve heard of &#8211; AlwaysOn, SSIS enhancements, etc&#8230;</p>
<p>Read the announcement here: <a href="http://blogs.technet.com/b/dataplatforminsider/archive/2011/07/11/sql-server-code-name-denali-ctp3-is-here.aspx">http://blogs.technet.com/b/dataplatforminsider/archive/2011/07/11/sql-server-code-name-denali-ctp3-is-here.aspx</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2011/07/12/sql-server-denali-ctp-3-released/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Quick Tip: Error: 18456, Severity: 14, State: 38.</title>
		<link>http://www.ssistalk.com/2011/05/06/quick-tip-error-18456-severity-14-state-38/</link>
		<comments>http://www.ssistalk.com/2011/05/06/quick-tip-error-18456-severity-14-state-38/#comments</comments>
		<pubDate>Fri, 06 May 2011 15:01:53 +0000</pubDate>
		<dc:creator>Phil Brammer</dc:creator>
				<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Server 2008]]></category>

		<guid isPermaLink="false">http://www.ssistalk.com/?p=267</guid>
		<description><![CDATA[When trying to investigate the SQL error, &#8220;Error: 18456, Severity: 14, State: 38.&#8221; it can be frustrating when not a single log on the system will tell you what the actual problem is.  In the case of state 38 (16 or 27 prior to SQL 2008) this error means the database specified in the [...]]]></description>
			<content:encoded><![CDATA[<p>When trying to investigate the SQL error, &#8220;Error: 18456, Severity: 14, State: 38.&#8221; it can be frustrating when not a single log on the system will tell you what the actual problem is.  In the case of state 38 (16 or 27 prior to SQL 2008) this error means the database specified in the client connection does not exist, or is offline.  In a large shop with many various clients it can be hard to find out the source of the connection, so you&#8217;re option is to use the tools at your disposal.  </p>
<p>The SQL Error Log does not help much at all. Here&#8217;s what&#8217;s in the SQL Error log:<br />
2011-05-06 09:06:17.28 Logon       Error: 18456, Severity: 14, State: 38.<br />
2011-05-06 09:06:17.28 Logon       Login failed for user &#8216;DOMAIN\ssrs.service&#8217;. Reason: Failed to open the explicitly specified database. [CLIENT: 192.168.0.147]</p>
<p>The Windows Application log is not much help either.<br />
Login failed for user &#8216;DOMAIN\ssrs.service&#8217;. Reason: Failed to open the explicitly specified database. [CLIENT: 192.168.0.147]</p>
<p>In other words, useless for troubleshooting.  The way to obtain the database name the client is trying to connect to is to use SQL Server Profiler.</p>
<p>To set up SQL Server Profiler, connect to the SQL instance where the error is occuring and then track the following events:<br />
Errors and Warnings: User Error Message<br />
Security Audit: Audit Login Failed</p>
<p>For these two events, make sure you capture at least the following columns: ApplicationName, HostName, LoginName, SPID (required), StartTime, TextData (where the message text will be), Severity, State, ClientProcessID, and Error.</p>
<p><img src="http://www.ssistalk.com/SQL_login_failure_trace_config.png" alt="SQL Profiler Setup Screenshot" /></p>
<p>Then run the trace.  You&#8217;ll see the following data under the &#8220;User Error Message&#8221; event when the login failure occurs:<br />
Cannot open database &#8220;DatabaseName&#8221; requested by the login. The login failed.<br />
For the &#8220;Audit Login Failed&#8221; event you&#8217;ll see the following data:<br />
Login failed for user &#8216;BLUENE\ssrs.service&#8217;. Reason: Failed to open the explicitly specified database. [CLIENT: 192.168.0.147]</p>
<p>Using this information (and the rest of the info in the other columns you selected), you should be able to go to the source and identify which process is trying to connect to the specified database and take appropriate action.</p>
<p>If you&#8217;re interested in the other states that error 18456 can generate, please visit fellow MVP Aaron Bertrand&#8217;s <a href="http://sqlblog.com/blogs/aaron_bertrand/archive/2011/01/14/sql-server-v-next-denali-additional-states-for-error-18456.aspx">page on this topic</a> for a very nice listing.  </p>
<p>Attached is the SQL Profiler Trace Template for SQL 2008 instances if you want to import it instead of manually configuring SQL Profiler.  To import the template, in SQL Server Profiler, go to File->Templates and select Import&#8230;</p>
<p><a href="http://www.ssistalk.com/SQL_Login_Failures_Profiler_Template.tdf">SQL_Login_Failures_Profiler_Template.tdf</a> (860 bytes)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ssistalk.com/2011/05/06/quick-tip-error-18456-severity-14-state-38/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
<enclosure url="http://www.ssistalk.com/SQL_Login_Failures_Profiler_Template.tdf" length="860" type="audio/mpeg" />
		</item>
	</channel>
</rss>

