The Forum has been Updated
The code has been upgraded to the latest .NET core version. Please check instructions in the Community Announcements about migrating your account.
hiya,
as the title says, i want to select R_REPLY from the Reply table. and i dont know how to incorporate it into the current select statement where it is selecting the topics.
can anyone help me?
thansk
MaD2ko0l<
as the title says, i want to select R_REPLY from the Reply table. and i dont know how to incorporate it into the current select statement where it is selecting the topics.
can anyone help me?
thansk
MaD2ko0l<
© 1999-2010 MaD2ko0l
Posted
That's what I was afraid of :(. What db type are you using?
If you could put these lines
right before this line in forum.asp
And post the results. Maybe someone with your db type experience could help.
When I upgraded my MySql db I had the same issue. Rearranging the parenthesis fixed it. I think that's the problem here.<
Code:
Response.Write strSql & strSql6 & strSql3 & strSql7 & strSql4
Response.EndCode:
if strDBType = "mysql" then 'MySql specific codeWhen I upgraded my MySql db I had the same issue. Rearranging the parenthesis fixed it. I think that's the problem here.<
_-/Cripto9t\-_
Posted
hiya,
im using an access db
and this is the output i get
SELECT T.T_STATUS, T.CAT_ID, T.FORUM_ID, T.TOPIC_ID, T.T_VIEW_COUNT, T.T_SUBJECT, T.T_MESSAGE, T.T_AUTHOR, T.T_STICKY, T.T_REPLIES, T.T_UREPLIES, T.T_LAST_POST, T.T_LAST_POST_AUTHOR, T.T_LAST_POST_REPLY_ID, M.M_NAME, MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME FROM ((FORUM_MEMBERS M, FORUM_TOPICS T, FORUM_MEMBERS AS MEMBERS_1) LEFT JOIN FORUM_REPLY R ON (T.TOPIC_ID = R.TOPIC_ID AND R.R_AUTHOR = 1)) WHERE M.MEMBER_ID = T.T_AUTHOR AND T.T_LAST_POST_AUTHOR = MEMBERS_1.MEMBER_ID AND T.FORUM_ID = 1 AND T.T_LAST_POST > '20070712220933' GROUP BY T.TOPIC_ID HAVING COUNT(R.R_AUTHOR) > -1 ORDER BY T.T_LAST_POST DESC
Microsoft JET Database Engine error '80040e14'
Syntax error in JOIN operation.
/na/snitzprivate/forum.asp, line 354
<
im using an access db
and this is the output i get
SELECT T.T_STATUS, T.CAT_ID, T.FORUM_ID, T.TOPIC_ID, T.T_VIEW_COUNT, T.T_SUBJECT, T.T_MESSAGE, T.T_AUTHOR, T.T_STICKY, T.T_REPLIES, T.T_UREPLIES, T.T_LAST_POST, T.T_LAST_POST_AUTHOR, T.T_LAST_POST_REPLY_ID, M.M_NAME, MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME FROM ((FORUM_MEMBERS M, FORUM_TOPICS T, FORUM_MEMBERS AS MEMBERS_1) LEFT JOIN FORUM_REPLY R ON (T.TOPIC_ID = R.TOPIC_ID AND R.R_AUTHOR = 1)) WHERE M.MEMBER_ID = T.T_AUTHOR AND T.T_LAST_POST_AUTHOR = MEMBERS_1.MEMBER_ID AND T.FORUM_ID = 1 AND T.T_LAST_POST > '20070712220933' GROUP BY T.TOPIC_ID HAVING COUNT(R.R_AUTHOR) > -1 ORDER BY T.T_LAST_POST DESC
Microsoft JET Database Engine error '80040e14'
Syntax error in JOIN operation.
/na/snitzprivate/forum.asp, line 354
<
© 1999-2010 MaD2ko0l
Posted
After a ton of searches, someone finally came up with a decient simple answer that I could understand
.
Going with that syntax try replacing strSql6 with this
I hope this works. It will end an access mystery for me.<
The JetSQL syntax is:
FROM ((table1
INNER JOIN table2 ON ....)
INNER JOIN table3 ON ....)
INNER JOIN table4 ON ...
Going with that syntax try replacing strSql6 with this
Code:
strSql6 = " FROM ((" & strMemberTablePrefix & "MEMBERS M, "
strSql6 = strSql6 & strActivePrefix & "TOPICS T), "
strSql6 = strSql6 & strMemberTablePrefix & "MEMBERS AS MEMBERS_1) "
strSql6 = strSql6 & "LEFT JOIN " & strActivePrefix & "REPLY R "
strSql6 = strSql6 & "ON T.TOPIC_ID = R.TOPIC_ID AND R.R_AUTHOR = " & MemberID _-/Cripto9t\-_
Posted
Nope that doesn't work either. I was able to log on to my free site with an access db and try a few things before I got kicked off. No luck
. Hopefully someone will spot what I've done wrong.<
_-/Cripto9t\-_
Posted
i tryed this
it was straight out of access and now i get this error
You tried to execute a query that does not include the specified expression 'T_STATUS' as part of an aggregate function<
Code:
strSql6 = " FROM FORUM_MEMBERS M, (FORUM_TOPICS T INNER JOIN FORUM_REPLY R ON( T.TOPIC_ID = R.TOPIC_ID AND R.R_AUTHOR =" & MemberID & ")) , FORUM_MEMBERS AS MEMBERS_1"
it was straight out of access and now i get this error
You tried to execute a query that does not include the specified expression 'T_STATUS' as part of an aggregate function<
© 1999-2010 MaD2ko0l
Email Member
Message Member
Post Moderation
FileUpload
If you're having problems uploading, try choosing a smaller image.
Preview post
Send Topic
Loading...