Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: Database: MS SQL Server
 Timeout
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

scorpswolle
Starting Member

39 Posts

Posted - 18 February 2007 :  18:31:42  Show Profile
I'm getting the following error on my ASP page:

"Microsoft OLE DB Provider for SQL Server error '80040e31'

Timeout expired

/forum/pop_profile.asp, line 389


Line 389 is the following:
set rs2 = my_Conn.Execute(strsql)

This happens not in all profiles, only some.

Server Details:

- MS SQL Server 2005 Enterprise (all updates!)
- Windows Server 2003 64 Bit SP1

The Forum: http://www.the-scorpions.com/forum/default.asp

Test Account:

Login: snitz
Password: snitz


Thank You

Edited by - scorpswolle on 18 February 2007 18:33:31

HuwR
Forum Admin

United Kingdom
20595 Posts

Posted - 18 February 2007 :  18:36:46  Show Profile  Visit HuwR's Homepage
you have quite a modified forum, could you therefore possibly post a link to a text version of your inc_profile.asp so that we can see what line 389 is doing?
Go to Top of Page

ruirib
Snitz Forums Admin

Portugal
26364 Posts

Posted - 18 February 2007 :  18:37:57  Show Profile  Send ruirib a Yahoo! Message
You may try reindexing your database, though I'm not sure that it would remove the error. It may remove it, it may not.
This thread here has some code changes that can improve the performance of pop_profile:

http://forum.snitz.com/forum/topic.asp?TOPIC_ID=59576&SearchTerms=pop_profile.asp


Snitz 3.4 Readme | Like the support? Support Snitz too
Go to Top of Page

scorpswolle
Starting Member

39 Posts

Posted - 18 February 2007 :  18:51:41  Show Profile
Sure:

http://www.the-scorpions.com/files/inc_profile.txt

http://www.the-scorpions.com/files/pop_profile.txt




quote:
Originally posted by HuwR

you have quite a modified forum, could you therefore possibly post a link to a text version of your inc_profile.asp so that we can see what line 389 is doing?

Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 19 February 2007 :  08:28:55  Show Profile  Send pdrg a Yahoo! Message
To save looking it up - the following SQL is timing out on the server

'## Forum_SQL - Find all records for the member
strsql = "SELECT F.FORUM_ID"
strSql = strSql & ", T.TOPIC_ID"
strSql = strSql & ", T.T_SUBJECT"
strSql = strSql & ", T.T_STATUS"
strSql = strSql & ", T.T_LAST_POST"
strSql = strSql & ", T.T_REPLIES "
strSql = strSql & " FROM ((" & strTablePrefix & "FORUM F LEFT JOIN " & strTablePrefix & "TOPICS T"
strSql = strSql & " ON F.FORUM_ID = T.FORUM_ID) LEFT JOIN " & strTablePrefix & "REPLY R"
strSql = strSql & " ON T.TOPIC_ID = R.TOPIC_ID) "
strSql = strSql & " WHERE (T_DATE > '" & strStartDate & "') "
strSql = strSql & " AND (T.T_AUTHOR = " & ppMember_ID
strSql = strSql & " OR R.R_AUTHOR = " & ppMember_ID & ")"
strSql = strSql & " AND (T_STATUS < 2 OR R_STATUS < 2)"
strSql = strSql & " AND F.F_TYPE = 0"
strSql = strSql & " ORDER BY T.T_LAST_POST DESC, T.TOPIC_ID DESC"
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 19 February 2007 :  08:30:57  Show Profile  Send pdrg a Yahoo! Message
And based on that I'd hunch that this happens for users who've posted a lot, or that some archiving would help the situation?
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20595 Posts

Posted - 19 February 2007 :  08:48:33  Show Profile  Visit HuwR's Homepage
I would hazard a guess that also limiting the said query to returning only some records would help, say give it a limit of 50 or a 100 records, hopefully unless the meber whose profile you are viewing posts a lot of messages in private forums limiting it to 50 or 100 should still give you the last 20 records they posted in.
Go to Top of Page

ruirib
Snitz Forums Admin

Portugal
26364 Posts

Posted - 19 February 2007 :  09:02:32  Show Profile  Send ruirib a Yahoo! Message
A fix is posted in the link I provided... it reduced 20+ secs page generation times into less than 1 sec...


Snitz 3.4 Readme | Like the support? Support Snitz too
Go to Top of Page

scorpswolle
Starting Member

39 Posts

Posted - 19 February 2007 :  11:30:58  Show Profile
quote:
Originally posted by ruirib

A fix is posted in the link I provided... it reduced 20+ secs page generation times into less than 1 sec...



Thank you so much, that´s it!
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.21 seconds. Powered By: Snitz Forums 2000 Version 3.4.07