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: MOD Implementation
 Active Users 4.0 or other problem??
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

ROB
Junior Member

USA
347 Posts

Posted - 23 April 2002 :  21:08:04  Show Profile  Visit ROB's Homepage  Send ROB an AOL message  Send ROB an ICQ Message  Send ROB a Yahoo! Message
Since installing Active Users 4.0, I noticed a problem that only crops up when and if someone logs out.

They get the following error message:
quote:
Microsoft OLE DB Provider for SQL Server error '80040e14'

Incorrect syntax near the keyword 'AND'.

/forums/inc_functions.asp, line 1163


Line 1163 refers to this the red line in the following function (which has not been modified):
function chkForumModerator(fForum_ID, fMember_Name)
'## Forum_SQL
strSql = "SELECT mo.FORUM_ID "
strSql = strSql & " FROM " & strTablePrefix & "MODERATOR mo, " & strTablePrefix & "MEMBERS me "
strSql = strSql & " WHERE mo.FORUM_ID = " & fForum_ID & " "
strSql = strSql & " AND mo.MEMBER_ID = me.MEMBER_ID "

if strAuthType = "db" then
strSql = strSql & " AND me.M_NAME = '" & fMember_Name & "'"
elseif strAuthType = "nt" then
strSql = strSql & " AND me.M_USERNAME = '" & fMember_Name & "'"
end if

Set rsChk = Server.CreateObject("ADODB.Recordset")
rsChk.open strSql, my_Conn

if rsChk.bof or rsChk.eof then
chkForumModerator = "0"
else
chkForumModerator = "1"
end if
rsChk.close
set rsChk = nothing
end function


Leads me to believe there's a problem with the AND clause in the SQL statement. The strange thing is, everything else works. Login, logout works (in spite of the error message), etc.

Anyone have any clues why might have gone awry?

Jeff Hester
http://www.bigblueball.com
Absolutely everything about Instant Messaging & Chat

Nathan
Help Moderator

USA
7664 Posts

Posted - 23 April 2002 :  21:19:25  Show Profile  Visit Nathan's Homepage
My question is. . . what does the checkForumModerator function have to do with logging out?

<edit>
The only connection I can come up with between that function and Active users is that I use the same variable name fForum_ID in a function on active_users.asp. . . but I logged out from active_users.asp without any problems.

Nathan Bales
Snitz Exchange | Do's and Dont's

Edited by - Nathan on 23 April 2002 21:30:16
Go to Top of Page

ROB
Junior Member

USA
347 Posts

Posted - 23 April 2002 :  21:41:53  Show Profile  Visit ROB's Homepage  Send ROB an AOL message  Send ROB an ICQ Message  Send ROB a Yahoo! Message
Yeah, doesn't make any sense. I'll follow that lead.

I should have mentioned that logging out from certain pages works fine (like default.asp), but logging out from forum.asp or topic.asp causes the error.

Jeff Hester
http://www.bigblueball.com
Absolutely everything about Instant Messaging & Chat
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.38 seconds. Powered By: Snitz Forums 2000 Version 3.4.07