title: Cannot access database on SQL Server via my VPN
body: <p>I am using SQL Server 2014 and I need to access the database using a VPN. I have no issue logging on the SQL Server using my VPN but I can't expand the database or query it.</p>
  
  <p>When I click the database to expand it, I get the following message:</p>
  
  <pre><code>The database XXXX is not accessible. (ObjectExplorer)
  
  ------------------------------
  Program Location:
  
     at Microsoft.SqlServer.Management.UI.VSIntegration.ObjectExplorer.DatabaseNavigableItem.get_CanGetChildren()
     at Microsoft.SqlServer.Management.UI.VSIntegration.ObjectExplorer.NavigableItem.RequestChildren(IGetChildrenRequest request)
     at Microsoft.SqlServer.Management.UI.VSIntegration.ObjectExplorer.ExplorerHierarchyNode.BuildChildren(WaitHandle quitEvent)
  </code></pre>
  
  <p>If I query a table from the database, I get the following message:</p>
  
  <pre><code>Msg 916, Level 14, State 1, Line 2
  The server principal "Bi" is not able to access the database "HMS_ARL" under the current security context.
  </code></pre>
  
  <p>Any kind of help would be much appreciated.</p>