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

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 ADDON: Pop-up Topic Statistics 1.5
 New Topic  Topic Locked
 Printer Friendly
Previous Page | Next Page
Author Previous Topic Topic Next Topic
Page: of 4

dayve
Forum Moderator

USA
5820 Posts

Posted - 19 November 2004 :  20:27:18  Show Profile  Visit dayve's Homepage
170,000+ topics and it timed out, so I added a script timeout to the code to allow it to run completely and I ended up with a buffer limit exceeded about 20 minutes later, but it almost finished. About 50 records towards the end did not get the viewed totals. I may just continue anyway, but the script can not handle the update on somewhat large forums.


Edited by - dayve on 19 November 2004 20:28:00
Go to Top of Page

dayve
Forum Moderator

USA
5820 Posts

Posted - 19 November 2004 :  20:46:10  Show Profile  Visit dayve's Homepage
quote:

Around line 538 of forum.asp, 563 of active.asp find this:
& Topic_ViewCount &
And change it to this:
& PopStatLink(Topic_ViewCount, 1) &


in my version of active.asp, the view count field is Topic_View_Count so I had to edit it accordingly.

Go to Top of Page

Da_Stimulator
DEV Team Forum Moderator

USA
3373 Posts

Posted - 19 November 2004 :  21:47:21  Show Profile  Send Da_Stimulator an AOL message  Send Da_Stimulator a Yahoo! Message
quote:
Originally posted by dayve

170,000+ topics and it timed out, so I added a script timeout to the code to allow it to run completely and I ended up with a buffer limit exceeded about 20 minutes later, but it almost finished. About 50 records towards the end did not get the viewed totals. I may just continue anyway, but the script can not handle the update on somewhat large forums.



Is there any way I can accomodate this? maybe by splitting it up, grabbing records 1/4 at a time or something?

quote:

SQL Server Syntax Error


strsql = "ALTER TABLE " & strTablePrefix & "TOPICS ADD COLUMN"
strsql = strsql & " T_MEMVIEWED "
if strDBType = "access" then
strsql = strsql & "memo "
else
strsql = strsql & "VARCHAR "
end if


should be


strsql = "ALTER TABLE " & strTablePrefix & "TOPICS ADD "
if strDBType = "access" then
strsql = strsql & "COLUMN T_MEMVIEWED memo; "
else
strsql = strsql & "T_MEMVIEWED VARCHAR(255); "
end if


The VARCHAR(255) could actually be TEXT(16) if you wanted a SQL Server Memo field.

I'll change the script tonight when I have time to accomodate.

-Stim
Go to Top of Page

Da_Stimulator
DEV Team Forum Moderator

USA
3373 Posts

Posted - 20 November 2004 :  00:44:20  Show Profile  Send Da_Stimulator an AOL message  Send Da_Stimulator a Yahoo! Message
You were right about active.asp... hadnt realized that...

Download is updated. Thx again dayve :)

-Stim
Go to Top of Page

Da_Stimulator
DEV Team Forum Moderator

USA
3373 Posts

Posted - 20 November 2004 :  03:09:22  Show Profile  Send Da_Stimulator an AOL message  Send Da_Stimulator a Yahoo! Message
I know it probably dosnt help you out much now dayve, but I re-wrote the setup script to page through your records, perhaps solving the timeout. The script should now be able to handle large forums....

This 1.2 should be pretty stable... I also updated the cosmetic scope after browsin BSF and seeing your nifty changes...

-Stim
Go to Top of Page

dayve
Forum Moderator

USA
5820 Posts

Posted - 20 November 2004 :  03:24:51  Show Profile  Visit dayve's Homepage
I'll give it a whirl in the morning.

Go to Top of Page

Da_Stimulator
DEV Team Forum Moderator

USA
3373 Posts

Posted - 20 November 2004 :  03:47:56  Show Profile  Send Da_Stimulator an AOL message  Send Da_Stimulator a Yahoo! Message
Just dont forget to adjust the pagesize.... set at 100 with 170,000 topics, you'll be clicking "continue" at least 17,000 times... lol

-Stim
Go to Top of Page

dayve
Forum Moderator

USA
5820 Posts

Posted - 21 November 2004 :  00:23:51  Show Profile  Visit dayve's Homepage
Just found a bug. For some reason unknown to me right now, the count will be off if the id of one member exists in another members id. For example, my id #2 exists in 2268, 2649, etc. I will get a bogus count for every id that contains my id. I am going to examine your code to see why this is happening. You may not have noticed this on your forum because of the low number of members. But go into your database and manually add something like:

1, 10, 11

Then look at the stats, see if member 1 has 4 hits instead of 1.

Go to Top of Page

Da_Stimulator
DEV Team Forum Moderator

USA
3373 Posts

Posted - 21 November 2004 :  01:22:11  Show Profile  Send Da_Stimulator an AOL message  Send Da_Stimulator a Yahoo! Message
I noticed this on your site, I didnt know what to think of it... every time I viewed a topic it counted twice...

I'll review the code also

-Stim
Go to Top of Page

Da_Stimulator
DEV Team Forum Moderator

USA
3373 Posts

Posted - 21 November 2004 :  01:52:18  Show Profile  Send Da_Stimulator an AOL message  Send Da_Stimulator a Yahoo! Message
Got the fix...

Find the following code in pop_topic_stats.asp


 response.write("</td><td bgcolor=""" & strForumCellColor & """ align=""center"">" & Ubound(Split(splitstr, trs1("MEMBER_ID"))) & "</td></tr>" & vbNewLine)
	   totalView = totalView + Ubound(Split(splitstr, trs1("MEMBER_ID")))


and replace it with the following code...


	strTempStr = replace(splitstr, ",", "||")
	strTempStr = "|" & strTempStr & "|"
        response.write("</td><td bgcolor=""" & strForumCellColor & """ align=""center"">" & Ubound(Split(strTempStr, "|" & trs1("MEMBER_ID") & "|")) & "</td></tr>" & vbNewLine)
	totalView = totalView + Ubound(Split(strTempStr, "|" & trs1("MEMBER_ID") & "|"))


Download has been updated with bugfix

-Stim
Go to Top of Page

Tam
New Member

Sweden
56 Posts

Posted - 21 November 2004 :  06:30:12  Show Profile  Visit Tam's Homepage
I had to add "my_Conn.CursorLocation = adUseClient" in the setup-file for it to go past step 3.
I use MySQL. Not sure if this is the best way to fix it though :)
Go to Top of Page

Astralis
Senior Member

USA
1218 Posts

Posted - 21 November 2004 :  07:14:31  Show Profile  Send Astralis a Yahoo! Message
Wow...very nice. I used to use something like this for a version or two back. It's nice to see it come back. And, it's amazing how much work has been done for such a simple function. I like to see the cooperation on here. It feels like the Snitz I knew when I first discovered it almost three years ago.
Go to Top of Page

Da_Stimulator
DEV Team Forum Moderator

USA
3373 Posts

Posted - 21 November 2004 :  15:41:30  Show Profile  Send Da_Stimulator an AOL message  Send Da_Stimulator a Yahoo! Message
quote:
Originally posted by Tam

I had to add "my_Conn.CursorLocation = adUseClient" in the setup-file for it to go past step 3.
I use MySQL. Not sure if this is the best way to fix it though :)



Where in the setup file? there are few recrodsets opened.... are you talking about the paged section?

-Stim
Go to Top of Page

Tam
New Member

Sweden
56 Posts

Posted - 21 November 2004 :  15:48:18  Show Profile  Visit Tam's Homepage
I put it in the beginning before the first Conn object is opened:

set my_Conn = Server.CreateObject("ADODB.Connection")
my_Conn.CursorLocation = adUseClient
my_Conn.Open strConnString

I didn't try to put it anywhere else, since it worked as soon as I put it in

Edited to add:

Without that line, I get this error:

Error Type:
ADODB.Recordset (0x800A0CB3)
Current Recordset does not support bookmarks. This may be a limitation of the provider or of the selected cursortype.
/wov/forum/popup_setup.asp, line 67


Edited AGAIN to add:

Some more info about my setup taken from
Snitz-serverinfo if you need any of the info:


DBMS Name MySQL
DBMS Version 4.0.21-nt
GROUP BY Support 3
Heterogeneous Table Support 0
Identifier Case Sensitivity 8
Maximum Index Size 500
Maximum Row Size 0
Maximum Row Size Includes BLOB True
Maximum Tables in SELECT 31
Multiple Storage Objects False
Multi-Table Update False
NULL Collation Order 8
OLE Object Support 1
ORDER BY Columns in Select List True
Prepare Abort Behavior 2
Prepare Commit Behavior 2
Procedure Term
Provider Name MSDASQL.DLL
OLE DB Version 02.00
Provider Version 02.81.1117.0
Quoted Identifier Sensitivity 4
Schema Term
Schema Usage 0
SQL Support 259
Structured Storage 1
Subquery Support 0
Isolation Levels 1118464
Isolation Retention 0
Table Term table
User Name root
Pass By Ref Accessors True
Transaction DDL 8
Asynchable Abort False
Data Source Object Threading Model 1
Output Parameter Availability 4
Persistent ID Type 4
Multiple Parameter Sets True
Rowset Conversions on Command True
Multiple Results 1
Provider Friendly Name Microsoft OLE DB Provider for ODBC Drivers
Connection Status 1
Server Name localhost via TCP/IP
Open Rowset Support 0
Accessible Procedures False
Accessible Tables True
Integrity Enhancement Facility False
Outer Join Capabilities 123
Stored Procedures False
Driver Name myodbc3.dll
Driver Version 03.51.09
Driver ODBC Version 03.51
Like Escape Clause Y
Special Characters ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜáíóúñÑ
Max Columns in Group By 0
Max Columns in Index 32
Max Columns in Order By 0
Max Columns in Select 0
Max Columns in Table 0
Numeric Functions 16777215
SQL Grammar Support 1
Outer Joins Y
String Functions 491519
System Functions 7
Time/Date Functions 106495
File Usage 0
Active Statements 0
Password
Persist Security Info
User ID
Data Source
Window Handle
Location
Mode
Prompt 4
Connect Timeout 15
Extended Properties DRIVER={MySQL ODBC 3.51 Driver};DESC=;DATABASE=Snitz;SERVER=localhost;UID=*******;PASSWORD=*********;PORT=;SOCKET=;OPTION=4;STMT=;
Locale Identifier 1053
Initial Catalog
OLE DB Services -7
General Timeout
Autocommit Isolation Levels 4096



Edited by - Tam on 21 November 2004 16:12:48
Go to Top of Page

Pull My Finger
Starting Member

43 Posts

Posted - 23 November 2004 :  18:31:35  Show Profile
Maybe I did something wrong but....

After installing I noticed that topics that didn't have replies posted didn't show the members names who viewed topic in the popup window.

Side Note: Im running Snitz based GML Portal Forums v1.0.0

Go to Top of Page
Page: of 4 Previous Topic Topic Next Topic  
Previous Page | Next Page
 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.77 seconds. Powered By: Snitz Forums 2000 Version 3.4.07