user warning: members_page' doesn't exist query:

GarP - June 27, 2007 - 13:59
Project:Members
Version:5.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:wmostrey
Status:active
Description

Just updated the members module, ran update.php, and got the following warning ....

user warning: Table '***********_main.members_page' doesn't exist query: SELECT mid, page_title, menu, menu_title, url, access FROM members_page WHERE page=1 in /home/***********/public_html/includes/database.mysql.inc on line 172.

Being new to Drupal, was not sure what I need to do to resolve this issue.

Thanking you in advance for your help.

EGP

#1

wmostrey - June 27, 2007 - 14:07
Component:User interface» Code
Assigned to:Anonymous» wmostrey

I would advice you to uninstall the module and run this query in phpMyAdmin:

DELETE FROM system WHERE name='members'

Then download the newest version and try a clean install.

#2

MFH - June 28, 2007 - 17:46

sorry, w.r.t your previous answer : the table is well named "$PREFIX_members" where $PREFIX is the prefix used for all tables of the given drupal (sub-)site ?
(i.e. you use qb_query("... {table} ...") ?)

I also get an error:

user warning: You have an error in your SQL syntax near 'fields, encode_mailto, field_length, users_per_page) VALUES ('all_members', 'listin' at line 1 query: INSERT INTO m7_members_page (name, description, access, page, page_title, url, use_pager, page_header, page_header_format, page_footer, page_footer_format, page_empty, page_empty_format, menu, menu_title, block, block_title, users_per_block, block_more, block_use_page_header, block_header, block_header_format, block_use_page_footer, block_footer, block_footer_format, block_use_page_empty, block_empty, block_empty_format, roles, fields, encode_mailto, field_length, users_per_page) VALUES ('all_members', 'listing of members', '6,3', '1', 'List of all members', 'members/all', '0', '', '1', '', '1', '', '1', '0', '', '0', '', '', '0', '0', ' in /home/httpd/html/mysite/drupal/includes/database.mysql.inc on line 172.

#3

wmostrey - June 29, 2007 - 07:47

{table} is indeed always used, I believe this is an error from upgrading from a version prior to the big changes to the newer version. I added an uninstall option so it should be enough to disable the module, uninstall it and enable it again.

The INSERT has been fixed, as per your suggestion in the other issue. This is available on cvs already.

#4

wmostrey - July 3, 2007 - 12:28
Status:active» fixed

#5

fm - July 10, 2007 - 02:58

After installing the 5.x-1.x-dev 2007-Jul-09 version, I am getting the same warning that is reported in the first post of this thread.

user warning: Table '*****.members_page' doesn't exist query: SELECT mid, page_title, menu, menu_title, url, access FROM members_page WHERE page=1 in *****/drupal-5.1/includes/database.mysql.inc on line 172.

#6

fm - July 10, 2007 - 03:00
Status:fixed» active

oops, forgot to change the status

#7

wmostrey - July 10, 2007 - 15:43
Category:support request» bug report

Hi fm,

Did you upgrade from an old version of members or is this a clean install of the module?
You can find the CREATE command for MySQL in the members.install file.

#8

fm - July 10, 2007 - 16:56

I don't remember if I'd had it installed previously, but I'll look into manually executing the CREATE command from the install file as you've suggested.

#9

fm - July 10, 2007 - 19:24
Status:active» fixed

That seems to have worked.

#10

Anonymous - July 24, 2007 - 19:47
Status:fixed» closed

#11

mattrock - September 11, 2007 - 03:02
Status:closed» active

I am getting the same error. The module is not creating the table no matter what I try. When I try to build the table with the string from members.install file, MySQL returns this error...

ERROR 1064 : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '");

CREATE TABLE {members_page} (
        mid int(10) unsigned NOT NULL aut' at line 1

The MySQL version is 5.0.24a.

#12

rkendall - September 18, 2007 - 13:03

matrock, you can't just cut'n'paste an SQL string from an install file (unless you understand what you are doing). The string '{members_page}' is supposed to be substituted for the actual table name by drupal (in case it has a prefix).

If you don't have a table prefix, try removing the braces {} then it may work for you.

#13

wallan - November 25, 2007 - 11:24

I'm having the same problem. I'm attempting to upgrade from an older version of the module, but I'm not that familiar with SQL. Anybody have any advice?

#14

wmostrey - November 27, 2007 - 11:31

AllanDay, if you're upgrading from a very old version it is advised to disabled and uninstall the module and to enable it again.

#15

wallan - November 27, 2007 - 22:34

Ahhh...! I'm such a fool! I hadn't realised that there's a specific uninstall action - I thought you meant disable the module and run update.php. Thanks wmostrey!

 
 

Drupal is a registered trademark of Dries Buytaert.