Recent Topics

1 Oct 10, 2006 17:33    

Hi,

b2evolution 1.8.2 uploaded on french provider "free.fr" with PHP Version 4.4.3-dev & mysql 5.0.25.

[u]During new installation of release 1.8.2 the following error occurs :[/u]

Created table «evo_groups»
Created table «evo_blogusers»
Created table «evo_settings»
Created table «evo_users»
Created table «evo_blogs»
Created table «evo_coll_settings»
Created table «evo_categories»
Created table «evo_posts»
Created table «evo_postcats»
Created table «evo_comments»
Created table «evo_locales»

Fatal error: mysql_num_fields(): supplied argument is not a valid MySQL result resource in /mnt/135/free.fr/d/4/le.ral.eur/inc/_misc/_db.class.php on line 621

[u]The same message is displayed by removing Table from b2evolution" :[/u]

Dropping Filetypes table...
Dropping Antispam table...
Dropping Hit-Logs...
Dropping Comments...
Dropping Categories-to-Posts relationships...
Dropping Links...
Dropping Files...
Dropping Posts...
Dropping Categories...
Dropping Post Statuses...
Dropping Post Types...

Fatal error: mysql_num_fields(): supplied argument is not a valid MySQL result resource

in /mnt/121/sdc/0/9/..... ../blogs/inc/_misc/_db.class.php on line 621

Each time the installation stop.

Could you help me ?

Thanks

2 Oct 10, 2006 17:47

Does the error always occur on the same action "Created table «evo_locales»" and "Dropping Post Types..."?

Can you insert a


if( ! is_resource($this->result) )
{
  pre_dump($query, $this->result);
}


before the


  while( $i < @mysql_num_fields($this->result) )

Strange: the "@" should suppress any error with mysql_num_fields() - but it's good that it gets at least displayed for you..

3 Oct 10, 2006 19:22

It always give me the same error on the same action (in my case the prefixe is evoV2_).

[u]Please find bellow the answer :[/u]

* for removing, the error is always :

Dropping Filetypes table...

'DROP TABLE IF EXISTS evoV2_filetypes'
true

Dropping Antispam table...

'DROP TABLE IF EXISTS evoV2_antispam'
true

Dropping Hit-Logs...

'DROP TABLE IF EXISTS evoV2_hitlog'
true

Dropping Comments...

'DROP TABLE IF EXISTS evoV2_comments'
true

Dropping Categories-to-Posts relationships...

'DROP TABLE IF EXISTS evoV2_postcats'
true

Dropping Links...

'DROP TABLE IF EXISTS evoV2_links'
true

Dropping Files...

'DROP TABLE IF EXISTS evoV2_files'
true

Dropping Posts...

'DROP TABLE IF EXISTS evoV2_posts'
true

Dropping Categories...

'DROP TABLE IF EXISTS evoV2_categories'
true

Dropping Post Statuses...

'DROP TABLE IF EXISTS evoV2_poststatuses'
true

Dropping Post Types...

'DROP TABLE IF EXISTS evoV2_posttypes'
true


Fatal error: mysql_num_fields(): supplied argument is not a valid MySQL result resource in /mnt/121/sdc/0/9/.../blogsv2/inc/_misc/_db.class.php on line 625

* for creating table, the error is always the same after using PhpMyadmin to delete table evoV2_ :


Created table «evoV2_groups»

'CREATE TABLE evoV2_groups (
grp_ID int(11) NOT NULL auto_increment,
grp_name varchar(50) NOT NULL default \'\',
grp_perm_admin enum(\'none\',\'hidden\',\'visible\') NOT NULL default \'visible\',
grp_perm_blogs enum(\'user\',\'viewall\',\'editall\') NOT NULL default \'user\',
grp_perm_stats enum(\'none\',\'view\',\'edit\') NOT NULL default \'none\',
grp_perm_spamblacklist enum(\'none\',\'view\',\'edit\') NOT NULL default \'none\',
grp_perm_options enum(\'none\',\'view\',\'edit\') NOT NULL default \'none\',
grp_perm_users enum(\'none\',\'view\',\'edit\') NOT NULL default \'none\',
grp_perm_templates TINYINT NOT NULL DEFAULT 0,
grp_perm_files enum(\'none\',\'view\',\'add\',\'edit\') NOT NULL default \'none\',
PRIMARY KEY grp_ID (grp_ID)
)'
true

Created table «evoV2_blogusers»

'CREATE TABLE evoV2_blogusers (
bloguser_blog_ID int(11) unsigned NOT NULL default 0,
bloguser_user_ID int(11) unsigned NOT NULL default 0,
bloguser_ismember tinyint NOT NULL default 0,
bloguser_perm_poststatuses set(\'published\',\'deprecated\',\'protected\',\'private\',\'draft\') NOT NULL default \'\',
bloguser_perm_delpost tinyint NOT NULL default 0,
bloguser_perm_comments tinyint NOT NULL default 0,
bloguser_perm_cats tinyint NOT NULL default 0,
bloguser_perm_properties tinyint NOT NULL default 0,
bloguser_perm_media_upload tinyint NOT NULL default 0,
bloguser_perm_media_browse tinyint NOT NULL default 0,
bloguser_perm_media_change tinyint NOT NULL default 0,
PRIMARY KEY bloguser_pk (bloguser_blog_ID,bloguser_user_ID)
)'
true

Created table «evoV2_settings»

'CREATE TABLE evoV2_settings (
set_name VARCHAR( 30 ) NOT NULL ,
set_value VARCHAR( 255 ) NULL ,
PRIMARY KEY ( set_name )
)'
true

Created table «evoV2_users»

'CREATE TABLE evoV2_users (
user_ID int(11) unsigned NOT NULL auto_increment,
user_login varchar(20) NOT NULL,
user_pass CHAR(32) NOT NULL,
user_firstname varchar(50) NULL,
user_lastname varchar(50) NULL,
user_nickname varchar(50) NULL,
user_icq int(11) unsigned NULL,
user_email varchar(255) NOT NULL,
user_url varchar(255) NULL,
user_ip varchar(15) NULL,
user_domain varchar(200) NULL,
user_browser varchar(200) NULL,
dateYMDhour datetime NOT NULL,
user_level int unsigned DEFAULT 0 NOT NULL,
user_aim varchar(50) NULL,
user_msn varchar(100) NULL,
user_yim varchar(50) NULL,
user_locale varchar(20) DEFAULT \'en-EU\' NOT NULL,
user_idmode varchar(20) NOT NULL DEFAULT \'login\',
user_allow_msgform TINYINT NOT NULL DEFAULT \'1\',
user_notify tinyint(1) NOT NULL default 1,
user_showonline tinyint(1) NOT NULL default 1,
user_grp_ID int(4) NOT NULL default 1,
user_validated TINYINT(1) NOT NULL DEFAULT 0,
PRIMARY KEY user_ID (user_ID),
UNIQUE user_login (user_login),
KEY user_grp_ID (user_grp_ID)
)'
true

Created table «evoV2_blogs»

'CREATE TABLE evoV2_blogs (
blog_ID int(11) unsigned NOT NULL auto_increment,
blog_shortname varchar(12) NULL default \'\',
blog_name varchar(50) NOT NULL default \'\',
blog_tagline varchar(250) NULL default \'\',
blog_description varchar(250) NULL default \'\',
blog_longdesc TEXT NULL DEFAULT NULL,
blog_locale VARCHAR(20) NOT NULL DEFAULT \'en-EU\',
blog_access_type VARCHAR(10) NOT NULL DEFAULT \'index.php\',
blog_siteurl varchar(120) NOT NULL default \'\',
blog_staticfilename varchar(30) NULL default NULL,
blog_stub VARCHAR(255) NOT NULL DEFAULT \'stub\',
blog_urlname VARCHAR(255) NOT NULL DEFAULT \'urlname\',
blog_notes TEXT NULL,
blog_keywords tinytext,
blog_allowcomments VARCHAR(20) NOT NULL default \'post_by_post\',
blog_allowtrackbacks TINYINT(1) NOT NULL default 1,
blog_allowpingbacks TINYINT(1) NOT NULL default 0,
blog_allowblogcss TINYINT(1) NOT NULL default 1,
blog_allowusercss TINYINT(1) NOT NULL default 1,
blog_pingb2evonet TINYINT(1) NOT NULL default 0,
blog_pingtechnorati TINYINT(1) NOT NULL default 0,
blog_pingweblogs TINYINT(1) NOT NULL default 0,
blog_pingblodotgs TINYINT(1) NOT NULL default 0,
blog_default_skin VARCHAR(30) NOT NULL DEFAULT \'custom\',
blog_force_skin TINYINT(1) NOT NULL default 0,
blog_disp_bloglist TINYINT(1) NOT NULL DEFAULT 1,
blog_in_bloglist TINYINT(1) NOT NULL DEFAULT 1,
blog_links_blog_ID INT(11) NULL DEFAULT NULL,
blog_commentsexpire INT(4) NOT NULL DEFAULT 0,
blog_media_location ENUM( \'default\', \'subdir\', \'custom\', \'none\' ) DEFAULT \'default\' NOT NULL,
blog_media_subdir VARCHAR( 255 ) NULL,
blog_media_fullpath VARCHAR( 255 ) NULL,
blog_media_url VARCHAR( 255 ) NULL,
blog_UID VARCHAR(20),
PRIMARY KEY blog_ID (blog_ID),
UNIQUE KEY blog_urlname (blog_urlname)
)'
true

Created table «evoV2_coll_settings»

'CREATE TABLE evoV2_coll_settings (
cset_coll_ID INT(11) UNSIGNED NOT NULL,
cset_name VARCHAR( 30 ) NOT NULL,
cset_value VARCHAR( 255 ) NULL,
PRIMARY KEY ( cset_coll_ID, cset_name )
)'
true

Created table «evoV2_categories»

'CREATE TABLE evoV2_categories (
cat_ID int(11) unsigned NOT NULL auto_increment,
cat_parent_ID int(11) unsigned NULL,
cat_name tinytext NOT NULL,
cat_blog_ID int(11) unsigned NOT NULL default 2,
cat_description VARCHAR(250) NULL DEFAULT NULL,
cat_longdesc TEXT NULL DEFAULT NULL,
cat_icon VARCHAR(30) NULL DEFAULT NULL,
PRIMARY KEY cat_ID (cat_ID),
KEY cat_blog_ID (cat_blog_ID),
KEY cat_parent_ID (cat_parent_ID)
)'
true

Created table «evoV2_posts»

'CREATE TABLE evoV2_posts (
post_ID int(11) unsigned NOT NULL auto_increment,
post_parent_ID int(11) unsigned NULL,
post_creator_user_ID int(11) unsigned NOT NULL,
post_lastedit_user_ID int(11) unsigned NULL,
post_assigned_user_ID int(11) unsigned NULL,
post_datestart datetime NOT NULL,
post_datedeadline datetime NULL,
post_datecreated datetime NULL,
post_datemodified datetime NOT NULL,
post_status enum(\'published\',\'deprecated\',\'protected\',\'private\',\'draft\') NOT NULL default \'published\',
post_pst_ID int(11) unsigned NULL,
post_ptyp_ID int(11) unsigned NULL,
post_locale VARCHAR(20) NOT NULL DEFAULT \'en-EU\',
post_content text NULL,
post_title text NOT NULL,
post_urltitle VARCHAR(50) NULL DEFAULT NULL,
post_url VARCHAR(255) NULL DEFAULT NULL,
post_main_cat_ID int(11) unsigned NOT NULL,
post_flags SET( \'pingsdone\', \'imported\'),
post_views INT(11) UNSIGNED NOT NULL DEFAULT 0,
post_wordcount int(11) default NULL,
post_comment_status ENUM(\'disabled\', \'open\', \'closed\') NOT NULL DEFAULT \'open\',
post_commentsexpire DATETIME DEFAULT NULL,
post_renderers TEXT NOT NULL,
post_priority int(11) unsigned null,
PRIMARY KEY post_ID( post_ID ),
UNIQUE post_urltitle( post_urltitle ),
INDEX post_datestart( post_datestart ),
INDEX post_main_cat_ID( post_main_cat_ID ),
INDEX post_creator_user_ID( post_creator_user_ID ),
INDEX post_status( post_status ),
INDEX post_parent_ID( post_parent_ID ),
INDEX post_assigned_user_ID( post_assigned_user_ID ),
INDEX post_ptyp_ID( post_ptyp_ID ),
INDEX post_pst_ID( post_pst_ID )
)'
true

Created table «evoV2_postcats»

'CREATE TABLE evoV2_postcats (
postcat_post_ID int(11) unsigned NOT NULL,
postcat_cat_ID int(11) unsigned NOT NULL,
PRIMARY KEY postcat_pk (postcat_post_ID,postcat_cat_ID),
UNIQUE catpost ( postcat_cat_ID, postcat_post_ID )
)'
true

Created table «evoV2_comments»

'CREATE TABLE evoV2_comments (
comment_ID int(11) unsigned NOT NULL auto_increment,
comment_post_ID int(11) unsigned NOT NULL default \'0\',
comment_type enum(\'comment\',\'linkback\',\'trackback\',\'pingback\') NOT NULL default \'comment\',
comment_status ENUM(\'published\', \'deprecated\', \'protected\', \'private\', \'draft\') DEFAULT \'published\' NOT NULL,
comment_author_ID int unsigned NULL default NULL,
comment_author varchar(100) NULL,
comment_author_email varchar(255) NULL,
comment_author_url varchar(255) NULL,
comment_author_IP varchar(23) NOT NULL default \'\',
comment_date datetime NOT NULL,
comment_content text NOT NULL,
comment_karma int(11) NOT NULL default \'0\',
comment_spam_karma TINYINT NULL,
comment_allow_msgform TINYINT NOT NULL DEFAULT \'0\',
PRIMARY KEY comment_ID (comment_ID),
KEY comment_post_ID (comment_post_ID),
KEY comment_date (comment_date),
KEY comment_type (comment_type)
)'
true

Created table «evoV2_locales»

'CREATE TABLE evoV2_locales (
loc_locale varchar(20) NOT NULL default \'\',
loc_charset varchar(15) NOT NULL default \'iso-8859-1\',
loc_datefmt varchar(10) NOT NULL default \'y-m-d\',
loc_timefmt varchar(10) NOT NULL default \'H:i:s\',
loc_startofweek TINYINT UNSIGNED NOT NULL DEFAULT 1,
loc_name varchar(40) NOT NULL default \'\',
loc_messages varchar(20) NOT NULL default \'\',
loc_priority tinyint(4) UNSIGNED NOT NULL default \'0\',
loc_enabled tinyint(4) NOT NULL default \'1\',
PRIMARY KEY loc_locale( loc_locale )
) COMMENT=\'saves available locales\'
'
true


Fatal error: mysql_num_fields(): supplied argument is not a valid MySQL result resource in /mnt/121/sdc/0/9/..../blogsv2/inc/_misc/_db.class.php on line 625

* or (without using Phpmyadmin to delete previous created tables) :



Created table «evoV2_categories»

'CREATE TABLE evoV2_categories (
cat_ID int(11) unsigned NOT NULL auto_increment,
cat_parent_ID int(11) unsigned NULL,
cat_name tinytext NOT NULL,
cat_blog_ID int(11) unsigned NOT NULL default 2,
cat_description VARCHAR(250) NULL DEFAULT NULL,
cat_longdesc TEXT NULL DEFAULT NULL,
cat_icon VARCHAR(30) NULL DEFAULT NULL,
PRIMARY KEY cat_ID (cat_ID),
KEY cat_blog_ID (cat_blog_ID),
KEY cat_parent_ID (cat_parent_ID)
)'
true

Created table «evoV2_posts»

'CREATE TABLE evoV2_posts (
post_ID int(11) unsigned NOT NULL auto_increment,
post_parent_ID int(11) unsigned NULL,
post_creator_user_ID int(11) unsigned NOT NULL,
post_lastedit_user_ID int(11) unsigned NULL,
post_assigned_user_ID int(11) unsigned NULL,
post_datestart datetime NOT NULL,
post_datedeadline datetime NULL,
post_datecreated datetime NULL,
post_datemodified datetime NOT NULL,
post_status enum(\'published\',\'deprecated\',\'protected\',\'private\',\'draft\') NOT NULL default \'published\',
post_pst_ID int(11) unsigned NULL,
post_ptyp_ID int(11) unsigned NULL,
post_locale VARCHAR(20) NOT NULL DEFAULT \'en-EU\',
post_content text NULL,
post_title text NOT NULL,
post_urltitle VARCHAR(50) NULL DEFAULT NULL,
post_url VARCHAR(255) NULL DEFAULT NULL,
post_main_cat_ID int(11) unsigned NOT NULL,
post_flags SET( \'pingsdone\', \'imported\'),
post_views INT(11) UNSIGNED NOT NULL DEFAULT 0,
post_wordcount int(11) default NULL,
post_comment_status ENUM(\'disabled\', \'open\', \'closed\') NOT NULL DEFAULT \'open\',
post_commentsexpire DATETIME DEFAULT NULL,
post_renderers TEXT NOT NULL,
post_priority int(11) unsigned null,
PRIMARY KEY post_ID( post_ID ),
UNIQUE post_urltitle( post_urltitle ),
INDEX post_datestart( post_datestart ),
INDEX post_main_cat_ID( post_main_cat_ID ),
INDEX post_creator_user_ID( post_creator_user_ID ),
INDEX post_status( post_status ),
INDEX post_parent_ID( post_parent_ID ),
INDEX post_assigned_user_ID( post_assigned_user_ID ),
INDEX post_ptyp_ID( post_ptyp_ID ),
INDEX post_pst_ID( post_pst_ID )
)'
true

Created table «evoV2_postcats»

'CREATE TABLE evoV2_postcats (
postcat_post_ID int(11) unsigned NOT NULL,
postcat_cat_ID int(11) unsigned NOT NULL,
PRIMARY KEY postcat_pk (postcat_post_ID,postcat_cat_ID),
UNIQUE catpost ( postcat_cat_ID, postcat_post_ID )
)'
true

Created table «evoV2_comments»

'CREATE TABLE evoV2_comments (
comment_ID int(11) unsigned NOT NULL auto_increment,
comment_post_ID int(11) unsigned NOT NULL default \'0\',
comment_type enum(\'comment\',\'linkback\',\'trackback\',\'pingback\') NOT NULL default \'comment\',
comment_status ENUM(\'published\', \'deprecated\', \'protected\', \'private\', \'draft\') DEFAULT \'published\' NOT NULL,
comment_author_ID int unsigned NULL default NULL,
comment_author varchar(100) NULL,
comment_author_email varchar(255) NULL,
comment_author_url varchar(255) NULL,
comment_author_IP varchar(23) NOT NULL default \'\',
comment_date datetime NOT NULL,
comment_content text NOT NULL,
comment_karma int(11) NOT NULL default \'0\',
comment_spam_karma TINYINT NULL,
comment_allow_msgform TINYINT NOT NULL DEFAULT \'0\',
PRIMARY KEY comment_ID (comment_ID),
KEY comment_post_ID (comment_post_ID),
KEY comment_date (comment_date),
KEY comment_type (comment_type)
)'
true

Created table «evoV2_antispam»

'CREATE TABLE evoV2_antispam (
aspm_ID bigint(11) NOT NULL auto_increment,
aspm_string varchar(80) NOT NULL,
aspm_source enum( \'local\',\'reported\',\'central\' ) NOT NULL default \'reported\',
PRIMARY KEY aspm_ID (aspm_ID),
UNIQUE aspm_string (aspm_string)
)'
true

Created table «evoV2_poststatuses»

'CREATE TABLE evoV2_poststatuses (
pst_ID int(11) unsigned not null AUTO_INCREMENT,
pst_name varchar(30) not null,
primary key ( pst_ID )
)'
true

Created table «evoV2_posttypes»

'CREATE TABLE evoV2_posttypes (
ptyp_ID int(11) unsigned not null AUTO_INCREMENT,
ptyp_name varchar(30) not null,
primary key (ptyp_ID)
)'
true

Created table «evoV2_files»

'CREATE TABLE evoV2_files (
file_ID int(11) unsigned not null AUTO_INCREMENT,
file_root_type enum(\'absolute\',\'user\',\'group\',\'collection\') not null default \'absolute\',
file_root_ID int(11) unsigned not null default 0,
file_path varchar(255) not null default \'\',
file_title varchar(255),
file_alt varchar(255),
file_desc text,
primary key (file_ID),
unique file (file_root_type, file_root_ID, file_path)
)'
true

Created table «evoV2_useragents»

'CREATE TABLE evoV2_useragents (
agnt_ID INT UNSIGNED NOT NULL AUTO_INCREMENT,
agnt_signature VARCHAR(250) NOT NULL,
agnt_type ENUM(\'rss\',\'robot\',\'browser\',\'unknown\') DEFAULT \'unknown\' NOT NULL ,
PRIMARY KEY (agnt_ID)
)'
true

Created table «evoV2_hitlog»

'CREATE TABLE evoV2_hitlog (
hit_ID INT(11) NOT NULL AUTO_INCREMENT,
hit_sess_ID INT UNSIGNED,
hit_datetime DATETIME NOT NULL,
hit_uri VARCHAR(250) DEFAULT NULL,
hit_referer_type ENUM(\'search\',\'blacklist\',\'referer\',\'direct\') NOT NULL,
hit_referer VARCHAR(250) DEFAULT NULL,
hit_referer_dom_ID INT UNSIGNED DEFAULT NULL,
hit_blog_ID int(11) UNSIGNED NULL DEFAULT NULL,
hit_remote_addr VARCHAR(40) DEFAULT NULL,
hit_agnt_ID INT UNSIGNED NULL,
PRIMARY KEY (hit_ID),
INDEX hit_datetime ( hit_datetime ),
INDEX hit_blog_ID (hit_blog_ID)
)'
true

Created table «evoV2_subscriptions»

'CREATE TABLE evoV2_subscriptions (
sub_coll_ID int(11) unsigned not null,
sub_user_ID int(11) unsigned not null,
sub_items tinyint(1) not null,
sub_comments tinyint(1) not null,
primary key (sub_coll_ID, sub_user_ID)
)'
true


Fatal error: mysql_num_fields(): supplied argument is not a valid MySQL result resource in /mnt/121/sdc/0/9/..../blogsv2/inc/_misc/_db.class.php on line 625

Thanks :D

4 Oct 10, 2006 20:08

Hmm.. please try this:
1. Remove the added code again:


if( ! is_resource($this->result) ) 
{ 
   pre_dump($query, $this->result); 
}


2. Add "if( is_resource($this->result) )" in front of the two while statements there, so that they look like:


if( is_resource($this->result) ) while( $i < @mysql_num_fields($this->result) )


and


if( is_resource($this->result) ) while( $row = @mysql_fetch_object($this->result) )

And add the same to the mysql_free_result() call:


if( is_resource($this->result) ) @mysql_free_result($this->result);

5 Oct 10, 2006 22:56

Great ! :D

It seems to be good.

Thanks blueyed for your support.

;)

6 Oct 10, 2006 23:27

Great. Will be fixed in 1.8.3.


Form is loading...