title: SSMS Error - “Attempted to read or write protected memory” - Accessing Localhost - Edit 200 rows
body: <p>So, I was running a localhost SQL Server and I tried to edit the first 200 rows of a table. Then I have received this (the original is in German, I found this one through the net):</p>
  
  <p><a href="https://i.stack.imgur.com/4EGJN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4EGJN.png" alt="enter image description here"></a></p>
  
  <p>After this, SSMS closes. 
  I researched and I found out that this is a known issue, if the PATH variable is more than 2K signs. Mine is 1336, so the problem should be somewhere else.</p>
  
  <p>This is the path variable:</p>
  
  <pre><code>C:\Program Files\Common Files\Microsoft Shared\Windows Live;
  C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;
  C:\ProgramData\Oracle\Java\javapath;
  C:\Program Files (x86)\Intel\iCLS Client\;
  C:\Program Files\Intel\iCLS Client\;
  %SystemRoot%\system32;
  %SystemRoot%;
  %SystemRoot%\System32\Wbem;
  %SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;
  C:\Program Files\Intel\WiFi\bin\;
  C:\Program Files\Common Files\Intel\WirelessCommon\;
  C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;
  C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;
  C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;
  C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;%systemroot%\System32\WindowsPowerShell\v1.0\;
  C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\110\Tools\Binn\;
  C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Binn\ManagementStudio\;
  C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Binn\;
  C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;
  C:\Program Files (x86)\Microsoft SQL Server\120\DTS\Binn\;
  C:\Program Files\Microsoft SQL Server\120\DTS\Binn\;
  C:\Program Files (x86)\Windows Live\Shared;
  C:\Program Files\Git\cmd;%USERPROFILE%\.dnx\bin;
  C:\Program Files\Microsoft DNX\Dnvm\;
  C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;
  C:\Program Files\TortoiseSVN\bin
  </code></pre>
  
  <p>Sometimes, depending on my luck I even do not get an error message but this:
  <a href="https://i.stack.imgur.com/EGg7E.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/EGg7E.png" alt="enter image description here"></a></p>
  
  <p>It means that the SSMS is going to be restarted.</p>
  
  <p><strong>Additional points:</strong></p>
  
  <ul>
  <li>SQL Server 2014</li>
  <li>The issue exists just on localhost. If I connect to a server, it is ok.</li>
  <li>I have enough RAM.</li>
  <li>Localhost was working for about a day, but somehow decided to make this.</li>
  </ul>
  
  <p><strong>What I have tried:</strong></p>
  
  <ul>
  <li>Restart the pc :)</li>
  <li>Drop and rebuild DB    </li>
  <li>Count the signs in the PATH variable</li>
  <li>Installing the latest version from here -> <a href="https://msdn.microsoft.com/en-us/library/mt238290.aspx" rel="nofollow noreferrer">https://msdn.microsoft.com/en-us/library/mt238290.aspx</a></li>
  </ul>
  
  <p><strong>Further info and updates:</strong></p>
  
  <ul>
  <li><p>I have no repair option in Add/Remove Programs:
  <a href="https://i.stack.imgur.com/bMBK2.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/bMBK2.png" alt="enter image description here"></a></p></li>
  <li><p>The DB was created by me using SSMS 2014. It had nothing to do with previous versions.</p></li>
  <li><p>The error appears after trying to edit the first 200 rows:
  <a href="https://i.stack.imgur.com/ASuwP.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ASuwP.png" alt="enter image description here"></a></p></li>
  <li><p>Error details on the error message (In German, but the language is not that important):</p></li>
  </ul>
  
  <p>Important EDIT - this seems to be important!
  This is the info from the studio:</p>
  
  <p>Microsoft SQL Server Management Studio                      12.0.2000.8</p>
  
  <p>Microsoft Analysis Services-Clienttools                     12.0.2000.8</p>
  
  <p>Microsoft Data Access Components (MDAC)                     10.0.10586.0</p>
  
  <p>Microsoft MSXML                     3.0 6.0 </p>
  
  <p>Microsoft .NET Framework                        4.0.30319.42000</p>
  
  <p>Betriebssystem                      6.3.10586</p>
  
  <p>Concerning the server:</p>
  
  <ul>
  <li><p>the one in the cloud without problems is 12.0.4213</p></li>
  <li><p>the localhost one where the problems appear is 13.0.1100</p></li>
  </ul>
  
  <p>I think this should be something.</p>