We help IT Professionals succeed at work.

ODBC Timeout Error for a View

qhanrahan asked
I have a view that is join between a table in the SQL database and a view in the SQL database.  When I try to open it via Open View, Return Top (10) the following error message appears:

[Microsoft] [ODBC SQL Server Driver] Timeout expired

When I click on the help button it shows the following:

ODBC error: <0s>.
An ODBC error has been generated. You might have deleted a record that has a foreign key value related to it, or you might have violated a check constraint.
For details, refer to your ODBC documentation.

Why this is an ODBC error I don't understand since the source data is all directly in SQL Server.

Also when I run the select statement used to create the view in Query Analyzer it runs without a problem.
Watch Question

Senior DBA
(1)  Through Query Analyzer, the timeout is effectively infinite.  However, through Enterprise Manager, the timeout is set at some fixed (and relatively small) value.  When you execute the query:


in Query Analyzer, how long does QA take to complete the query?

(2)  QA And Enterprise Manager use ODBC to connect to the SQL Server DB, even if they are running on the same machine.

(3)  Ignore the HELP you saw.  It's incorrect - a minor status display bug.


The query is taking a long time to complete as the tables involved are huge.  I was a little unnerved when I saw the ODBC error because I was unaware it was being used.  

Explore More ContentExplore courses, solutions, and other research materials related to this topic.