Using Drupal v 4.6.3 and User_import


// $Id: user_import.module,v 1.9.2.1 2005/11/28 02:33:55 MegaGrunt Exp $

Loading /admin/settings/user_import returns a blank page (using clean URLs).

Not having this problem with other modules. Tested with default themes.

Not a noob error. MySQL tables installed. Modules turned on, etc.

Comments

robert castelo’s picture

Do you get the tabs at the top of the content section: 'list imports', 'add import', 'configure'?

Do you get any of the Drupal page, header, sidecontent,...?

agentrickard’s picture

Nope. Nothing. Totally blank. As in: there is a PHP error somewhere and this page has loaded null.

Tested while running bluemarine theme to be sure I hadn't broken anything themewise.

Any other specs you need for debugging?

agentrickard’s picture

Hm.. I've been in a rush, so I installed on my test box. And got a different error. Page loads, but with this error at top:

user error: Table 'drupalbase.user_import' doesn't exist
query: SELECT * FROM user_import WHERE setting != 'saved' in /Library/WebServer/htdocs/drupalbase/includes/database.mysql.inc on line 66.

This is after I have loaded the user_import.mysql file through PHPMyAdmin.

Strange. The code executes, but no table is being created.

SQL query: 
#
# Table structure for table `user_import`
#
CREATE TABLE `user_import` (
`iid` int( 10 ) unsigned NOT NULL AUTO_INCREMENT ,
`name` varchar( 25 ) NOT NULL default '',
`file_handle` varchar( 20 ) NOT NULL default '',
`started` int( 11 ) NOT NULL default '0',
`pointer` int( 10 ) NOT NULL default '0',
`total` int( 10 ) NOT NULL default '0',
`processed` int( 10 ) NOT NULL default '0',
`valid` int( 10 ) NOT NULL default '0',
`first_line` int( 1 ) NOT NULL default '0',
`contact` int( 1 ) NOT NULL default '0',
`send_email` int( 1 ) NOT NULL default '0',
`field_match` longtext NOT NULL ,
`username` varchar( 100 ) NOT NULL default '',
`abbreviate` varchar( 100 ) NOT NULL default '',
`roles` varchar( 255 ) NOT NULL default '',
`setting` varchar( 10 ) NOT NULL default '',
PRIMARY KEY ( `iid` )
) TYPE = MYISAM AUTO_INCREMENT =60;

# --------------------------------------------------------
#
# Table structure for table `user_import_errors`
#
CREATE TABLE `user_import_errors` (
`iid` int( 10 ) NOT NULL default '0',
`data` longtext NOT NULL ,
`error` varchar( 25 ) NOT NULL default '',
KEY `iid` ( `iid` )
) TYPE = MYISAM ;

When I loaded the file using PHPMyAdmin's textfile browser, the tables were not created. When I omitted the comments and just loaded the SQL statements manually, then the tables were created.

Here's what I loaded successfully:


CREATE TABLE `user_import` (
`iid` int( 10 ) unsigned NOT NULL AUTO_INCREMENT ,
`name` varchar( 25 ) NOT NULL default '',
`file_handle` varchar( 20 ) NOT NULL default '',
`started` int( 11 ) NOT NULL default '0',
`pointer` int( 10 ) NOT NULL default '0',
`total` int( 10 ) NOT NULL default '0',
`processed` int( 10 ) NOT NULL default '0',
`valid` int( 10 ) NOT NULL default '0',
`first_line` int( 1 ) NOT NULL default '0',
`contact` int( 1 ) NOT NULL default '0',
`send_email` int( 1 ) NOT NULL default '0',
`field_match` longtext NOT NULL ,
`username` varchar( 100 ) NOT NULL default '',
`abbreviate` varchar( 100 ) NOT NULL default '',
`roles` varchar( 255 ) NOT NULL default '',
`setting` varchar( 10 ) NOT NULL default '',
PRIMARY KEY ( `iid` )
) TYPE = MYISAM AUTO_INCREMENT =60;


CREATE TABLE `user_import_errors` (
`iid` int( 10 ) NOT NULL default '0',
`data` longtext NOT NULL ,
`error` varchar( 25 ) NOT NULL default '',
KEY `iid` ( `iid` )
) TYPE = MYISAM ;

So I think this is user error compounded by a bad MYSQL file. Will check on my other installation.

agentrickard’s picture

Priority: Critical » Normal
Status: Active » Needs review

Yup. It works now. I was wrong initially (didn't check for table creation).

The problem is in the MYSQL file in the current distro.

Nice module! ++

agentrickard’s picture

This module is really sweet. Great stuff. Really. Especially the "test import" and error capture.

Love it.

robert castelo’s picture

Status: Needs review » Fixed
robert castelo’s picture

Status: Fixed » Closed (fixed)