Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 time out expired error

Author  Topic 

sponguru_dba
Yak Posting Veteran

93 Posts

Posted - 2006-07-06 : 04:57:38
hi

I have table with 10 columns,that table having 10 lack record,


from appication one query running that is picking up the data like this

SELECT <all fields> FROM TABLE1 where NAME<varchar(20)> AND TEXTID<varchar(122)>

some time this query giving error like "time out expired error" any how it is very slow how can solve this problem


regards
sree

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2006-07-06 : 05:03:15
quote:
Originally posted by sponguru_dba

hi

I have table with 10 columns,that table having 10 lack record,


from appication one query running that is picking up the data like this

SELECT <all fields> FROM TABLE1 where NAME<varchar(20)> AND TEXTID<varchar(122)>

some time this query giving error like "time out expired error" any how it is very slow how can solve this problem


regards
sree




Is there any index on the columns in the where clause? Also whether you are using Like to match the column values?

and BTW, was it a valid T-SQL at all?


Harsh Athalye
India.
"Nothing is Impossible"
Go to Top of Page

sponguru_dba
Yak Posting Veteran

93 Posts

Posted - 2006-07-06 : 06:02:19
No "index" on where clause no "like" in sql statement
Go to Top of Page

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2006-07-06 : 06:22:07
quote:
Originally posted by sponguru_dba

No "index" on where clause no "like" in sql statement




If these are the frequently accessed columns, I will suggest putting Index on them (so that Table Scans can be avoided). Also, can u tell me how many rows are returned by this query? Would u mind posting original query here?

Harsh Athalye
India.
"Nothing is Impossible"
Go to Top of Page
   

- Advertisement -