 




<?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>SQL Server with Rick Martinez &#187; SQL Login</title>
	<atom:link href="http://itknowledgeexchange.techtarget.com/martinez-sql-server/tag/sql-login/feed/" rel="self" type="application/rss+xml" />
	<link>http://itknowledgeexchange.techtarget.com/martinez-sql-server</link>
	<description>When  it comes to performing your daily SQL Server Tasks, technical documentation tends to tell you more than what you need to know! This blog covers the basics and beyond demonstrating the techniques and functionality offered in SQL Server.</description>
	<lastBuildDate>Tue, 19 Oct 2010 21:52:50 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>SQL Server Login SID</title>
		<link>http://itknowledgeexchange.techtarget.com/martinez-sql-server/sql-server-login-sid/</link>
		<comments>http://itknowledgeexchange.techtarget.com/martinez-sql-server/sql-server-login-sid/#comments</comments>
		<pubDate>Fri, 02 Apr 2010 15:45:59 +0000</pubDate>
		<dc:creator>Rick Martinez</dc:creator>
				<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Login]]></category>
		<category><![CDATA[SQL Security]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[T-SQL]]></category>

		<guid isPermaLink="false">http://itknowledgeexchange.techtarget.com/martinez-sql-server/sql-server-login-sid/</guid>
		<description><![CDATA[If you restore a database on a second sql server and you need to be changing the sql login every time you restore that database you can use CREATE LOGIN. You can use the following sql to create the account on the second server using the same sid from server 1. BOL]]></description>
				<content:encoded><![CDATA[<p>If you restore a database on a second sql server and you need to be changing the sql login every time you restore that database you can use CREATE LOGIN. You can use the following sql to create the account on the second server using the same sid from server 1. <a href="http://msdn.microsoft.com/en-us/library/ms189751.aspx">BOL</a></p>
<pre class="brush: sql; title: ; notranslate">
--check existing users on SERVER
select name, sid from dbo.syslogins

--create the account with the same sid from server 1
create login rickmartinez
with
	password = 'pa$$word',
	sid = 0x02D76C40D8B6BD41BB809DA2DA58590D,
	default_database = yourdatabasename,
	default_language = English
</pre>
<!-- wpms-network-global-inserts -->]]></content:encoded>
			<wfw:commentRss>http://itknowledgeexchange.techtarget.com/martinez-sql-server/sql-server-login-sid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
