Click here to Skip to main content
16,004,602 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi Expert,

For My Winform application, I have Used sql server 2005 as Backend.

There are more than 9 lacs entries in a Companyinfo table.and Around 10 lacs data in emailinfo table which is secondory Table.


Currently i am inserting 50 rows using stored procedure,

This sp is very complex,in which i am checking duplicate entries,updating status,category,date,user etc of duplicate entries.

Currently there are 10 users.

from last 15 days, this sp working slow,and showing
timeout expired the timeout period elapsed
error usually.

I have traced sp using sql profiler,it shows
CPU : 4094
, reads 236310 writes 40

i set server transaction timeout=40

My other heavy stored procedure for same databse working fine,from which i am inserting 1000 rows within seconds.

Please Help me to sort this problem.

Thanks in advance

And sorry for poor english.
Posted
Comments
Rockstar_ 30-May-13 7:52am    
You can use sql server Profiler, which is available in Tools menu of SSMS...
udusat13 30-May-13 8:13am    
Thanks for suggestion.

 
Share this answer
 
v4
Comments
udusat13 30-May-13 8:12am    
thanks for links and reply.
Hi udusat1,

I think this is not the problem with your SP, it is not properly indexed, first check integrity constraints are their on the tables or not, and implement indexing on the tables, so that it will increase speed of crud operations on your database.

Thanks
SP
 
Share this answer
 
v2
Comments
udusat13 30-May-13 8:12am    
Thanks For your reply,
I have indexed the table.
udusat13 7-Jun-13 2:30am    
The table was poorly indexed.

Now Its working fine.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900