Author |
Topic  |
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 04 June 2008 : 16:36:28
|
Well, I wish I had good news. Here's the routine without the strSql= bits:
And here's the result:
quote:
Microsoft VBScript runtime error '800a01a8' Object required: 'g'
/itw/test.asp, line 8
No change, except for leaner code.< |
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 04 June 2008 : 21:46:36
|
OK - Response Writing Sql after line 1 results in this:
after line 2:
So far, so good.
after line 3:
Hanging in there. But after line 4, I'm back to the error message. Adding M. to the order routine doesn't fix it, G. won't work because it's in the M table, but I tried it anyway. Same error.
Deleting the order routine doesn't have any effect, same error.
The problem seems to REALLY be in the fourth line. If I switch the order of comparing the two member IDs, the error changes to object required "M" - but still referring to the first line of strSql.
So far, still baffled. < |
Edited by - Carefree on 04 June 2008 21:47:24 |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 04 June 2008 : 21:50:12
|
I did notice that the error switches from a small letter "g" to a capital letter "M". I have no idea why it uses a small "g", though.
If I do not compare the two Member ID's, the error goes away, but the procedure cannot work. Maybe a join command will have to be used, but not sure how to word it.< |
Edited by - Carefree on 04 June 2008 22:04:13 |
 |
|
AnonJr
Moderator
    
United States
5768 Posts |
Posted - 04 June 2008 : 21:53:01
|
I suspect the part in red needs to be the variable of the MEMBER_ID you're looking for.
< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 04 June 2008 : 22:11:12
|
Just on the off-chance that the letter G was causing the error, I switched all of Gs to the letter N. No good. Now object required 'n'< |
 |
|
AnonJr
Moderator
    
United States
5768 Posts |
Posted - 04 June 2008 : 22:40:31
|
Because the part I highlighted in red in my previous post is not a part of the string you are building, VBScript is looking for an object "G" to do/get/set "MEMBER_ID"
If you're looking for a particular member, you'll need to replace the part in red with wherever you're holding the member ID.< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 04 June 2008 : 22:58:21
|
OK, I rewrote it with a join statement:
and I get a new error:
quote:
Syntax error in FROM clause.
test.asp, line 17
Of course, line 17 isn't the problem, it's the execution line.
Here's the Response Write of the strSql:
quote:
SELECT USERGROUP_USERS.USERGROUP_ID, USERGROUP_USERS.MEMBER_ID FROM FORUM_USERGROUP_USERS, JOIN FORUM_MEMBERS ON USERGROUP_USERS.MEMBER_ID = MEMBERS.MEMBER_ID SELECT MEMBERS.M_NAME WHERE USERGROUP_USERS.USERGROUP_ID = 8, ORDER BY MEMBERS.M_NAME
< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 04 June 2008 : 23:01:48
|
quote: Originally posted by AnonJr
Because the part I highlighted in red in my previous post is not a part of the string you are building, VBScript is looking for an object "G" to do/get/set "MEMBER_ID"
If you're looking for a particular member, you'll need to replace the part in red with wherever you're holding the member ID.
G.MEMBER_ID was in the first line of the code.< |
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 05 June 2008 : 06:47:55
|
Ahhhh - not as a variable to be read.... Can't believe I didn't try that.... Thanks.
Now if I can only figure out why the body list isn't populating.< |
 |
|
AnonJr
Moderator
    
United States
5768 Posts |
Posted - 05 June 2008 : 08:35:56
|
What are you trying to accomplish? i.e. are you trying to get a list of all the members in Group 8?< |
 |
|
Carefree
Advanced Member
    
Philippines
4222 Posts |
Posted - 05 June 2008 : 09:24:59
|
I got that part fixed. Now I have a new error (this project will drive me to drink).
Here's the Release routine:
And here's the release form:
I'm getting this error message:
quote:
Microsoft JET Database Engine error '80040e10'
No value given for one or more required parameters.
Line 84 (the my_conn.execute line)
But here's the result of the strSql:
quote:
SELECT MEMBER_ID FROM FORUM_MEMBERS WHERE M_NAME = Testing123
Does the member name require quotation marks?< |
Edited by - Carefree on 05 June 2008 09:31:26 |
 |
|
Shaggy
Support Moderator
    
Ireland
6780 Posts |
Posted - 05 June 2008 : 09:30:26
|
Yes.
< |
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
 |
|
Topic  |
|