I install the Leech (5.x-1.x-dev 2007-Feb-08) and activate only the leech module and the node_template module. I am getting in the watchdog this can of error:
- Table '...._drpl1.leech_opml' doesn't exist query: SELECT * FROM leech_opml WHERE nid = 379 in line 172 ..../includes/database.mysql.inc.
- Table '...._drpl1.leech' doesn't exist query: SELECT * FROM leech WHERE nid = 379 in line 172 .....includes/database.mysql.inc.
- ....others same errors for others tables.
It seem that 5.x-1.x version don't create the tables en mysql when the modules are activated from admin/build/modules and the permisions set correctly. I check the database and the tables are not created.
I don't know if we need to create the tables with sql file and i think i am messing this file? Or maybe the modules scripts are messing something to get the install file executed?
I am using mysql 4.1
Apreciate any help to get leeck working. Thanks

Comments

JymBrittain’s picture

I have a similar problem..
I get to the create a template story part of the instructions and get these errors:

* user warning: Table 'drupal.leech_news_feed' doesn't exist query: SELECT * FROM leech_news_feed WHERE nid = 22 in /home/srv/www/htdocs/drupal/includes/database.mysql.inc on line 172.
* user warning: Table 'drupal.leech_news_item' doesn't exist query: SELECT i.*, n.title AS feed_title, f.links_display_mode, f.link AS feed_link, l.url AS feed_url FROM leech_news_item i LEFT JOIN node n ON n.nid = i.fid LEFT JOIN leech_news_feed f ON f.nid = i.fid LEFT JOIN leech l ON l.nid = i.fid WHERE i.nid = 22 in /home/srv/www/htdocs/drupal/includes/database.mysql.inc on line 172.
* user warning: Table 'drupal.leech' doesn't exist query: SELECT * FROM leech WHERE nid = 22 in /home/srv/www/htdocs/drupal/includes/database.mysql.inc on line 172.
* user warning: Table 'drupal.leech_opml' doesn't exist query: SELECT * FROM leech_opml WHERE nid = 22 in /home/srv/www/htdocs/drupal/includes/database.mysql.inc on line 172.

Additionally, when visiting /var/lib/mysql/drupal those tables do not exist.

JymBrittain’s picture

I manually created the tables as recommended in http://drupal.org/node/109090. I created leech, leech_news_feed, leech_news_item, leech_opml and node_template. Now I'm getting the error

user warning: Unknown column 'f.links_display_mode' in 'field list' query: SELECT i.*, n.title AS feed_title, f.links_display_mode, f.link AS feed_link, l.url AS feed_url FROM leech_news_item i LEFT JOIN node n ON n.nid = i.fid LEFT JOIN leech_news_feed f ON f.nid = i.fid LEFT JOIN leech l ON l.nid = i.fid WHERE i.nid = 22 in /home/srv/www/htdocs/drupal/includes/database.mysql.inc on line 172.

aron novak’s picture

Assigned: Unassigned » aron novak
Status: Active » Postponed (maintainer needs more info)

JymBrittain:
Are you sure that you used the correct mysql statements for creating the tables? I cannot reproduce this message: Unknown column 'f.links_display_mode' in 'field list'.

CREATE TABLE leech_news_feed (
        `nid` int(10) NOT NULL,
        `template` int(10) NOT NULL,
        `logo` varchar(255) NOT NULL default '',
        `link` text NOT NULL default '',
        `author` varchar(64) NOT NULL default '',
        `items_guid` tinyint(2) NOT NULL default '0',
        `items_status` tinyint(2) NOT NULL default '0',
        `items_update` tinyint(2) NOT NULL default '0',
        `items_delete` int(10) NOT NULL default '1000000000',
        `items_promote` int(10) NOT NULL default '1000000000',
        `items_date` tinyint(2) NOT NULL default '0',
        `links_display_mode` tinyint(3) unsigned NOT NULL default '0',
        PRIMARY KEY (`nid`)
        );

As you see there is a links_display_mode column. Please tell me the result of DESC leech_news_feed mysql statement!
geograt:
Perhaps leech was installed before on this Drupal site (then removed), that's why Drupal didn't get leech_install hook run.
If you experienced this on a completely fresh Drupal install please tell me the exact version of PHP and MySQL. Btw. Do you able to create the tables manually? (Practically enter the sql commands in leech.install file to the mysql console - take care of removing {} surround table names)

geograt’s picture

Leech was installed before and i experience this with fresh instalation.
I am using php 4.4.3 and mysql 4.1.21.
To go on this problem i create the tables manually and leech seem to work fine.
By the way, when creating the tables manually i get some errors from the executed sql, i get the same errors when i create tables manually in the last version of drupal but the tables are created and work fine.

JymBrittain’s picture

I used CREATE TABLE leech_opml (
`nid` int(10) NOT NULL,
`template` int(10) NOT NULL,
PRIMARY KEY (`nid`)
);
and duplicated this for the other table names.

JymBrittain’s picture

I used the create commands in the leech-install file and all is well.

aron novak’s picture

Status: Postponed (maintainer needs more info) » Closed (fixed)

JymBrittain: Thanks for the feedback that everything is okay now.
For everyone with similar SQL problem:
http://drupal.org/node/125100
Leech currently don't do uninstall/update according to Drupal style. It's an important thing to fix. So updating from an older version of the module is hard at the moment.