title: Client-side pyodbc error: "Server does not exist or access denied."
body: <p>I have a python application designed to pull data from a remote database server using pyodbc, then organize and display the data in a spreadsheet. I've had it working fine for several months now, with multiple coworkers in my department using it through a shared network folder.</p>
  
  <p>My connection:</p>
  
  <pre><code>pyodbc.connect('DRIVER={SQL Server};
                  SERVER=&lt;myServer_name&gt;;
                  DATABASE=&lt;myDB_name&gt;;
                  UID=personsUser;
                  PWD=personsPassword')
  </code></pre>
  
  <p>A different employee within our same network recently tried to use the program and got this error: </p>
  
  <pre><code>pyodbc.Error: ('08001','[08001][Microsoft][ODBC SQL Server Driver]
  [DBNETLIB]SQL Server does not exist or access denied. (17) (SQLDriverConnect)')
  </code></pre>
  
  <p>It looked like a simple permissions issue to me, so to confirm I replaced the userID and password with my own hardcoded in, but it gave the same error. Furthermore the same employee can log in and execute queries through SQL Server Management Studio without issue.</p>
  
  <p>Since everyone else in our department can still use the application fine, I know it must be a client-side issue, but I just can't pinpoint the problem. Any input would be greatly appreciated, Thanks!</p>
  
  <p><strong>Updates:</strong></p>
  
  <p>Per flipperPA's answer below, I updated my connection string to include the port:</p>
  
  <pre><code>con = pyodbc.connect('''DRIVER={SQL Server};
                          SERVER=&lt;myServer_name&gt;;
                          PORT=1433;
                          DATABASE=&lt;myDB_name&gt;;
                          UID=personsUser;
                          PWD=personsPassword;''')
  </code></pre>
  
  <p>Unfortunately we still got the same error.</p>
  
  <p>He is running 32-bit Windows 7 on an HP machine, the same setup as the rest of the group so it shouldn't to be an os-level issue.</p>
  
  <p>He does operate SSMS on the same machine, but I ran through the telnet check just be sure - no issue there.</p>
  
  <p>I've taught myself the pyodbc API and basic SQL, but I'm still relatively new to the underlying concepts of databases and remote connections. Could you explain the TDS driver a little more?</p>