Author |
Topic  |
|
bjlt
Senior Member
   
1144 Posts |
Posted - 03 June 2003 : 12:53:01
|
just now I searched for mobile palm, all forums, within messages.
error '80040e31' /forum/search.asp, line 375
I wonder how does a info database run, can we do something to eliminate this problem? |
|
HuwR
Forum Admin
    
United Kingdom
20600 Posts |
Posted - 03 June 2003 : 12:57:42
|
yes, rewrite the search page code specifically for this site, you could just try narrowing your search criteria and not choose 'Allforums' |
 |
|
bjlt
Senior Member
   
1144 Posts |
Posted - 03 June 2003 : 13:09:31
|
Thanks, then it's not a problem with the database but rather how one handles it?
Will the use of foreign keys, stored procedures help a little? or are there any sql statements could be refined?
|
 |
|
RichardKinser
Snitz Forums Admin
    
USA
16655 Posts |
Posted - 03 June 2003 : 14:26:34
|
you can try this one: Search by Category
Again, just don't choose "All Categories". |
 |
|
bjlt
Senior Member
   
1144 Posts |
Posted - 03 June 2003 : 15:02:19
|
 my question is actually, from a programmer's point of view, are there anything we can do to prevent time out from happening? |
Edited by - bjlt on 03 June 2003 15:05:20 |
 |
|
lofty
Junior Member
 
USA
158 Posts |
Posted - 03 June 2003 : 18:17:00
|
Yes there are ways to optimize the searching, including stored procedures. The problem is that the optimizations most likely will not work with Access 2000 or mySQL. I believe some people have already created mods or code for better and faster searching that work with MS SQL Server. For small-medium sites, the default searching is just fine, and usually doesn't time out. For very large sites such as this, you probably wouldn't use Access as your DB, which leaves SQL Server and mySQL as your choices. Since mySQL doesn't support stored procedures yet, a large site running SQL Server could take advantage of an improved searching MOD that uses stored procedures or other optimizations.
Snitz still needs to support Access and mySQL, so this seems best suited to being a MOD, rather than an out of the box change to the search page. |
 |
|
D3mon
Senior Member
   
United Kingdom
1685 Posts |
Posted - 03 June 2003 : 18:29:57
|
quote: Originally posted by bjlt
 my question is actually, from a programmer's point of view, are there anything we can do to prevent time out from happening?
It might not prevent a timeout, but: Search.asp make a lot of resource/time expensive request.querystring and request.form calls...
Writing these to variables right at the start of the code might sped things up like:
Dim QSandor,QSmode,QSSearch,QSMemberID,QSSearchMessage,QSForum,QSForumID,QSSearchDate,QSSearchMember
with request
QSandor = .form("andor")
QSmode = .querystring("mode")
QSSearch = .form("Search")
QSMemberID = .form("MEMBER_ID")
QSSearchMessage = .form("SearchMessage")
QSForum = .form("Forum")
QSForumID = .form("FORUM_ID")
QSSearchDate = .form("SearchDate")
QSSearchMember = .form("SearchMember")
end with Then search and replace all the request.[whatever]("[whatever]") with the associated variable. |
 Snitz 'Speedball' : Site Integration Mod : Friendly Registration Mod "In war, the victorious strategist only seeks battle after the victory has been won" |
 |
|
|
Topic  |
|