Print Page | Close Window

High database usage

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=27644
Printed Date: 02 April 2026 at 2:16pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: High database usage
Posted By: slepix
Subject: High database usage
Date Posted: 30 July 2009 at 12:01pm
Hi, I am administering a sql machine, and one of my clients has webwiz forum installed. Often I can see querys running for 35-40 seconds. Query that is running that long is:

SELECT TOP 750 tblForum.Forum_ID, tblForum.Forum_name, tblForum.Password, tblForum.Forum_code, tblTopic.Topic_ID, tblTopic.Poll
tblTopic.Moved_ID, tblTopic.Subject, tblTopic.Icon, tblTopic.No_of_replies, tblTopic.No_of_views, tblTopic.Locked, tblTopic.Priority, tblTopic
tblThread.Thread_ID, tblThread.Message_date, tblThread.Message, tblThread.Author_ID, tblAuthor.Username, tblTopic.Event_date FROM
tblCategory WITH (NOLOCK) , tblForum WITH (NOLOCK) , tblTopic WITH (NOLOCK) , tblThread WITH (NOLOCK) , tblAuthor WITH (NOLO
WHERE tblCategory.Cat_ID = tblForum.Cat_ID AND tblForum.Forum_ID = tblTopic.Forum_ID AND tblTopic.Topic_ID = tblThread.Topic_ID
tblThread.Author_ID = tblAuthor.Author_ID AND tblForum.Forum_ID IN (7) AND (tblTopic.Forum_ID IN (SELECT tblPermissions.Forum_ID
FROM tblPermissions WITH (NOLOCK) WHERE (tblPermissions.Group_ID = 4 OR tblPermissions.Author_ID = 3045) AND
tblPermissions.View_Forum = 1)) AND (tblTopic.Hide = 0 OR tblThread.Author_ID = 3045) AND (tblThread.Hide=0 OR tblThread.Author_ID
3045) AND (tblThread.Message LIKE '%dac%') ORDER BY tblThread.Thread_ID DESC;


Is there any way to optimise database usage. Will the upgrade to the new version fix this problem?



Replies:
Posted By: WebWiz-Bruce
Date Posted: 30 July 2009 at 12:12pm
All queries in the software are optimised which is why pages take less than 0.05 seconds to process.

However the exception to this is when you run a search which as you can imagaine by it's very nature on large forums can take sometime to run as depending on the criteria the user is searching on and can take up to 60 seconds to run.

There are a number of tools to help reduce the impact of searches on performance many of which can be configured. They are listed below:-

1. Be default searches are for the last 6 months and not any date, unless the user changes this
2. Only 1 search can be carried out every 20 seconds from a particular IP

You can also edit the file search_process.asp to change the settings below:-

1. The number of topics or posts to return can be changed. By default it is 100.
2. The script timeout is set to 120 sounds
3. The database timeout is set to 60 seconds (no search query will last longer than this unless overridden on the database server)

By the look of the query you have you are using an older version which has the limit set at 750 results not 100. You should upgrade your forum to the latest release for improved performance and also to have some of the newer settings listed above.


-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting


Posted By: slepix
Date Posted: 30 July 2009 at 12:19pm
wow..this was fast :)  ok, I've reduced the number of posts to 100. I'll see how will that have the impact on the sql machine..thank you very much for your response.


Posted By: slepix
Date Posted: 30 July 2009 at 12:24pm
one more question, forum version installed is: http://www.webwizforums.com/" rel="nofollow - Web Wiz Forums version 8.02 . How complicated is the upgrade proccess, is there anything that need to have special attention when upgrading?


Posted By: WebWiz-Bruce
Date Posted: 30 July 2009 at 1:08pm
Upgrading is very simple, just overwrite the existing files with the ones from the latest release and then the installation wizard takes care of the database upgrading.

For more information see the upgrade documentation at the link below:-

http://www.webwiz.net/webwizforums/kb/


-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net