<rss version="2.0" 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:creativeCommons="http://backend.userland.com/creativeCommonsRssModule" xmlns:image="http://purl.org/rss/1.0/modules/image/">
    <channel>
        <title>MS SQL</title>
        <link>http://waynester.net/blog/category/33.aspx</link>
        <description>Microsoft SQL Server</description>
        <language>en-US</language>
        <copyright>Wayne Larimore</copyright>
        <generator>Subtext Version 2.1.2.2</generator>
        <creativeCommons:license>wlar1m0re</creativeCommons:license>
        <item>
            <title>Invalid User Password after Restore SQL Database</title>
            <link>http://waynester.net/blog/archive/2011/03/05/invalid-user-password-after-restore-sql-database.aspx</link>
            <description>&lt;p&gt;&lt;font size="2" face="Verdana"&gt;Recently I restored a MS SQL database from one server to another and starting getting an 'invalid user or password' error message.  What happened was the database user became 'orphaned' on the target server.  Here's how to remedy this problem:&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2" face="Verdana"&gt;Within SQL Management Studio run this command...&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2" face="Verdana"&gt;&lt;strong&gt;EXEC sp_change_users_login 'UPDATE_ONE','svcUser', 'svcUser'&lt;br /&gt;
&lt;/strong&gt;&lt;br /&gt;
where svcUser is the name of the user account being used to communicate with the database.&lt;/font&gt;&lt;/p&gt;&lt;img src="http://waynester.net/blog/aggbug/5778.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Wayne Larimore</dc:creator>
            <guid>http://waynester.net/blog/archive/2011/03/05/invalid-user-password-after-restore-sql-database.aspx</guid>
            <pubDate>Sat, 05 Mar 2011 19:54:21 GMT</pubDate>
            <wfw:comment>http://waynester.net/blog/comments/5778.aspx</wfw:comment>
            <comments>http://waynester.net/blog/archive/2011/03/05/invalid-user-password-after-restore-sql-database.aspx#feedback</comments>
            <wfw:commentRss>http://waynester.net/blog/comments/commentRss/5778.aspx</wfw:commentRss>
            <trackback:ping>http://waynester.net/blog/services/trackbacks/5778.aspx</trackback:ping>
        </item>
        <item>
            <title>Inserting Null Values For DateTime Sql Server Type</title>
            <link>http://waynester.net/blog/archive/2011/01/11/returning-null-values-for-datetime-sql-server-type.aspx</link>
            <description>&lt;p&gt;&lt;font face="Verdana"&gt;Here's how I return a null value for a sql data type of datetime:&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;newExpense.AMEXStatementDate = ConvertToDateTime(AMEXStatementDateTextBox.Text); &lt;/p&gt;
&lt;p&gt;private DateTime ConvertToDateTime(string value) &lt;br /&gt;
{ &lt;br /&gt;
if (!value.Equals(string.Empty)) &lt;br /&gt;
  return Convert.ToDateTime(value); &lt;br /&gt;
else &lt;br /&gt;
  return (DateTime)System.Data.SqlTypes.SqlDateTime.Null; &lt;br /&gt;
} &lt;br /&gt;
&lt;/p&gt;&lt;img src="http://waynester.net/blog/aggbug/5777.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Wayne Larimore</dc:creator>
            <guid>http://waynester.net/blog/archive/2011/01/11/returning-null-values-for-datetime-sql-server-type.aspx</guid>
            <pubDate>Wed, 12 Jan 2011 05:04:32 GMT</pubDate>
            <wfw:comment>http://waynester.net/blog/comments/5777.aspx</wfw:comment>
            <comments>http://waynester.net/blog/archive/2011/01/11/returning-null-values-for-datetime-sql-server-type.aspx#feedback</comments>
            <wfw:commentRss>http://waynester.net/blog/comments/commentRss/5777.aspx</wfw:commentRss>
            <trackback:ping>http://waynester.net/blog/services/trackbacks/5777.aspx</trackback:ping>
        </item>
        <item>
            <title>SSIS Package DTS Property Key not valid error</title>
            <link>http://waynester.net/blog/archive/2011/01/06/ssis-package-dts-property-key-not-valid-error.aspx</link>
            <description>&lt;p&gt;&lt;font face="Verdana"&gt;I recently built a SSIS package that included a web task and script task.  The web task called a remote web service to pull in needed data.  The script task wrote text files based on the data.  All worked great on my development environment.  However, once deployed it started throwing this error:&lt;/font&gt;&lt;/p&gt;
&lt;address&gt;Code: 0xC0016016     Source:       Description: Failed to decrypt protected XML node "DTS:Property" with error 0x8009000B "Key not valid for use in specified state.". You may not be authorized to access this information. This error occurs when there is a cryptographic error. Verify that the correct key is available.  End Error&lt;/address&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;Thanks to this &lt;/font&gt;&lt;a href="http://ppalakollu.blogspot.com/2007/10/moving-ssis-packages-from-development.html"&gt;&lt;font face="Verdana"&gt;blog entry&lt;/font&gt;&lt;/a&gt;&lt;font face="Verdana"&gt; I found the solution.  You basically need to set the Package Level Security to DontSaveSensitive.  To accomplish this, right-click on the Package and choose properies.  Inside the Security section you'll find the ProtectionLevel attribute.  Set it to DontSaveSensitive.&lt;/font&gt;&lt;/p&gt;&lt;img src="http://waynester.net/blog/aggbug/5776.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Wayne Larimore</dc:creator>
            <guid>http://waynester.net/blog/archive/2011/01/06/ssis-package-dts-property-key-not-valid-error.aspx</guid>
            <pubDate>Thu, 06 Jan 2011 14:44:10 GMT</pubDate>
            <wfw:comment>http://waynester.net/blog/comments/5776.aspx</wfw:comment>
            <comments>http://waynester.net/blog/archive/2011/01/06/ssis-package-dts-property-key-not-valid-error.aspx#feedback</comments>
            <wfw:commentRss>http://waynester.net/blog/comments/commentRss/5776.aspx</wfw:commentRss>
            <trackback:ping>http://waynester.net/blog/services/trackbacks/5776.aspx</trackback:ping>
        </item>
        <item>
            <title>SQL Server Service Pack 2 Fails with Fatal Error</title>
            <link>http://waynester.net/blog/archive/2008/10/21/SQL-Server-Service-Pack-2-Fails-with-Fatal-Error.aspx</link>
            <description>&lt;p&gt;I kept getting a Failure while applying Microsoft SQL Server 2005 Service Pack 2 today for 'Database Services' and 'Analysis Services'.  It was a brand new installation so I couldn't think of anything that would cause this.  I &lt;a target="_blank" href="http://support.microsoft.com/kb/925976"&gt;found a kb&lt;/a&gt; on Microsoft's site that fixed the failure for 'Database Services'.  I'm still getting the failure on Analysis Services.  I will update this post when I find the solution.&lt;/p&gt;&lt;img src="http://waynester.net/blog/aggbug/5740.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Wayne Larimore</dc:creator>
            <guid>http://waynester.net/blog/archive/2008/10/21/SQL-Server-Service-Pack-2-Fails-with-Fatal-Error.aspx</guid>
            <pubDate>Tue, 21 Oct 2008 21:32:56 GMT</pubDate>
            <wfw:comment>http://waynester.net/blog/comments/5740.aspx</wfw:comment>
            <comments>http://waynester.net/blog/archive/2008/10/21/SQL-Server-Service-Pack-2-Fails-with-Fatal-Error.aspx#feedback</comments>
            <wfw:commentRss>http://waynester.net/blog/comments/commentRss/5740.aspx</wfw:commentRss>
            <trackback:ping>http://waynester.net/blog/services/trackbacks/5740.aspx</trackback:ping>
        </item>
        <item>
            <title>Missing SQL Server Management Studio</title>
            <link>http://waynester.net/blog/archive/2008/10/21/Missing-SQL-Server-Management-Studio.aspx</link>
            <description>&lt;p&gt;&lt;strong&gt;Missing your SQL Server Management Studio after installing SQL Server 2005&lt;/strong&gt;?  When creating my Microsoft Office SharePoint Server (MOSS) development environment I had the same problem.  Thankfully, &lt;a href="http://blogs.neudesic.com/blogs/pete_orologas/archive/2006/10/12/416.aspx"&gt;Pete Orologas&lt;/a&gt; posted a solution and it worked for me.  Apparently, if there is already a \Program Files\Microsoft SQL Server\90\Tools folder that exists then the installer moves on to the next step.  How does that subfolder get there?  Well, if you install Visual Studio before SQL it creates the folder when installing SQL Express.  Or if you install the SQL Express edition it will create the tools folder.&lt;/p&gt;
&lt;h3&gt;THE SOLUTION?&lt;/h3&gt;
&lt;p&gt;Rename the Tools folder to something like Tools_bkup and run the "&lt;strong&gt;SqlRun_Tools&lt;/strong&gt;" exe or msi file.  This is located on the install media inside the {&lt;em&gt;drive&lt;/em&gt;}:\{&lt;em&gt;platform_specific_pathing&lt;/em&gt;}\&lt;strong&gt;Tools\Setup&lt;/strong&gt; subfolder.&lt;/p&gt;
&lt;p&gt;This worked for me.  I hope it helps in your situation.  Leave comments of your experience.&lt;/p&gt;&lt;img src="http://waynester.net/blog/aggbug/5739.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Wayne Larimore</dc:creator>
            <guid>http://waynester.net/blog/archive/2008/10/21/Missing-SQL-Server-Management-Studio.aspx</guid>
            <pubDate>Tue, 21 Oct 2008 15:36:23 GMT</pubDate>
            <wfw:comment>http://waynester.net/blog/comments/5739.aspx</wfw:comment>
            <comments>http://waynester.net/blog/archive/2008/10/21/Missing-SQL-Server-Management-Studio.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://waynester.net/blog/comments/commentRss/5739.aspx</wfw:commentRss>
            <trackback:ping>http://waynester.net/blog/services/trackbacks/5739.aspx</trackback:ping>
        </item>
    </channel>
</rss>
