﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / SQL Server 7,2000 / Service Packs  / SP4 Breaks Suser_sname() ? / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Tue, 21 May 2013 05:24:32 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: SP4 Breaks Suser_sname() ?</title><link>http://www.sqlservercentral.com/Forums/Topic236452-48-1.aspx</link><description>Thanks Thai, that is good to know.</description><pubDate>Fri, 06 Jan 2006 11:55:00 GMT</pubDate><dc:creator>Brian Munier</dc:creator></item><item><title>RE: SP4 Breaks Suser_sname() ?</title><link>http://www.sqlservercentral.com/Forums/Topic236452-48-1.aspx</link><description>&lt;P&gt;Hi Brian,&lt;/P&gt;&lt;P&gt;I guess the answer to your question is it depends.&lt;/P&gt;&lt;P&gt;With my limited testing in our environment, I've found this issue only affects NT login via group membership.&lt;/P&gt;&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;1) If Joe has access to SQL Server via his personal NT account, then in 'syslogins', you'll see a record for Joe with a sid value. When Joe logins to SQL Server, this sid value is used to populate 'sysprocesses' record, so no problem for suser_sname() here.&lt;/P&gt;&lt;P&gt;2) If Joe only has access to SQL Server via an NT group (Joe is a member of 'NTGroupA', and this group was granted access to SQL Server), When Joe logins to SQL Server, the server has to derive Joe's sid value via the NT group. Somewhere along this line, the sid value wasn't properly formatted, so if you run suser_sname() against this sid in sysprocesses, it would not match, therefore null result.&lt;/P&gt;&lt;P&gt;I hope this help.&lt;/P&gt;</description><pubDate>Wed, 04 Jan 2006 11:40:00 GMT</pubDate><dc:creator>THANG HOANG</dc:creator></item><item><title>RE: SP4 Breaks Suser_sname() ?</title><link>http://www.sqlservercentral.com/Forums/Topic236452-48-1.aspx</link><description>&lt;P&gt;An additional question for you THANG,&lt;/P&gt;&lt;P&gt;Did this bug also affect using Suser_sname() without a sid to get the name of the server login?&lt;/P&gt;&lt;P&gt;I am considering applying SP4, but I use this function for housekeeping.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Brian&lt;/P&gt;</description><pubDate>Thu, 29 Dec 2005 09:47:00 GMT</pubDate><dc:creator>Brian Munier</dc:creator></item><item><title>RE: SP4 Breaks Suser_sname() ?</title><link>http://www.sqlservercentral.com/Forums/Topic236452-48-1.aspx</link><description>&lt;P&gt;F.Y.I.&lt;/P&gt;&lt;P&gt;I did get a confirmation from Microsoft that this is a bug generated by SP4.&lt;/P&gt;&lt;P&gt;This problem is contributed by the data type inconsistency in the system tables. SID column in sysprocesses is a binary(86), while defined as a varbinary(85) in syslogins.&lt;/P&gt;&lt;P&gt;The work around is to cast the SID to a valid fix length of binary(28) in order for suser_sname() to work.&lt;/P&gt;&lt;P&gt;Microsoft has no known fix plan for the time being. They note Yukon isn't affected by this bug.&lt;/P&gt;</description><pubDate>Wed, 16 Nov 2005 12:28:00 GMT</pubDate><dc:creator>THANG HOANG</dc:creator></item><item><title>SP4 Breaks Suser_sname() ?</title><link>http://www.sqlservercentral.com/Forums/Topic236452-48-1.aspx</link><description>No one has responded to this topic yet. Even if you don't have a complete answer, the original poster will appreciate any thoughts you have!</description><pubDate>Mon, 14 Nov 2005 08:00:00 GMT</pubDate><dc:creator>Site Owners</dc:creator></item><item><title>SP4 Breaks Suser_sname() ?</title><link>http://www.sqlservercentral.com/Forums/Topic236452-48-1.aspx</link><description>&lt;P&gt;Our admin folk just applied SQL 2000 SP4 on a W2K3 machine, and I noticed system function suser_sname() is not working normally.&lt;/P&gt;&lt;P&gt;I have an sp that extracts suser_sname(sid) from master..sysprocesses for statistics purpose. Since the SP4 upgrade, suser_sname() will return NULL on some of the Windows domain sid, but not the others.&lt;/P&gt;&lt;P&gt;I also noticed sid column in sysprocesses is a varbinary(86), where sid column in sysxlogins is a varbinary(85). I am not sure if sysprocesses was modified by SP4 or has it always been this way ?&lt;/P&gt;&lt;P&gt;Any help is appreciated.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description><pubDate>Thu, 10 Nov 2005 16:47:00 GMT</pubDate><dc:creator>THANG HOANG</dc:creator></item></channel></rss>