php forum
php mysql forum
php mysql smarty
 
Topic Options
#224736 - 09/17/02 04:52 AM CREATE TABLE error
Aglavalin Offline
Enthusiast

Registered: 06/18/02
Posts: 394
Loc: Southern California
I am in the final steps of testing a new hack for ubbt to let moderators add users to selected groups, but I am getting some errors while creating a new table with the SQL Command box in the admin menu. The table is created correctly, and is usable, but gives the following error:<br /><br />Warning: mysql_num_fields(): supplied argument is not a valid MySQL result resource in c:\inetpub\wwwroot\www.newoutriders.org\ubbthreads\mysql.inc.php on line 155<br /><br />Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in c:\inetpub\wwwroot\www.newoutriders.org\ubbthreads\mysql.inc.php on line 121<br /> <br />Anyone have any ideas? I am using this SQL command, which is copied from Max's Calendar 3.0 hack (which gives the same error btw)<br /><br /><pre><font class="small">code:</font><hr><br />CREATE TABLE w3t_groupmods (<br /> GM_Username varchar(30) NOT NULL,<br /> GM_AddGroup tinyint(3) DEFAULT '3' NOT NULL,<br /> GM_RemoveGroup varchar(1) NOT NULL,<br /> KEY GM_Username (GM_Username)<br />);<br /></pre><hr>

Top
#224737 - 09/17/02 07:27 AM Re: CREATE TABLE error [Re: neuron]
Dave_L_dup1 Offline
Addict

Registered: 04/23/02
Posts: 1929
Loc: Virginia, USA
I got the same warnings when I tried that query with 6.1b2. The warnings do not occur if I do the query with phpMyAdmin or with the mysql command on the server. <br /> <br />I think the problem is that the script is attempting to display the query results, but the CREATE query does not produce any results. "CREATE" probably needs to be added to the list of commands for which results are not displayed. <br /> <br />In admin/dbdocommand.php: <br /> <br />if (!preg_match("/DELETE|INSERT|UPDATE|REPLACE|ALTER/i",$command)) { <br /> <br />Reported as bug.


Edited by Dave_L (09/17/02 09:09 AM)
_________________________
UBB.threads beta tester / threadsdev.com moderator
Software consulting services including UBB.threads problem resolution / installs / upgrades / customization.

Top
#224738 - 09/17/02 01:10 PM Re: CREATE TABLE error [Re: joeuser]
Aglavalin Offline
Enthusiast

Registered: 06/18/02
Posts: 394
Loc: Southern California
OK, well I guess my syntax is correct, so I'll keep this code and advise people to expect and then ignore the error in the hack directions.<br /><br />Thanks Dave_L! <img src="/forum/images/icons/smile.gif" alt="" />

Top


Who's Online
2 registered (GEN, Gizmo), 23 Guests and 9 Spiders online.
Key: Admin, Global Mod, Mod
Shout Box

Latest Posts
Spell Check [beta]
by Gizmo
12/01/08 06:21 PM
PhotoPost BB Code Popup
by AllenAyres
12/01/08 09:41 AM
Problems reading a lot of old posts here
by AllenAyres
12/01/08 09:35 AM
Forum 'Trader Ratings'.
by AllenAyres
12/01/08 09:33 AM
Customization needed
by Gizmo
11/12/08 12:28 PM
Team UBBDev Rides Again!
by AllenAyres
11/11/08 02:16 PM
Active Topics.
by AllenAyres
11/11/08 02:13 PM
New Mods
User Authentication Class
by
01/19/07 02:59 PM
Multiple Identity Detector
by
12/30/06 06:39 PM
PhotoPost BB Code Popup
by
11/06/06 05:43 PM
Spell Check [beta]
by
10/17/06 09:24 PM
Newest Members
David DelMonte, nick1, Begbie, cenk, MATTO
13363 Registered Users
Top Posters
AllenAyres 25452
JoshPet 11330
Rick 8372
LK 7396
Lord Dexter 6503
Greg Hard 5533
Charles Capps 5438

 

 

 
fusionbb message board php hacks