Hi i try to activate the module



    * user warning: 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 'DEFAULT' at line 6 query: CREATE TABLE flickrusers ( uid int(11) NOT NULL, flickrusername text NOT NULL, cachejpegs tinyint(1) NOT NULL default '0', PRIMARY KEY (uid) ) ENGINE=MyISAM DEFAULT in /home/web/site/includes/database.mysql.inc on line 172.
    * user warning: 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 'CURRENT_TIMESTAMP, PRIMARY KEY (flickrphoto_i query: CREATE TABLE flickrphotos ( flickrphoto_id int(11) NOT NULL, nid int(11) NOT NULL, lastfetched timestamp NOT NULL default CURRENT_TIMESTAMP, PRIMARY KEY (flickrphoto_id), UNIQUE KEY flickrphoto_id (flickrphoto_id), UNIQUE KEY nid (nid) ) ENGINE=MyISAM DEFAULT in /home/web/site/includes/database.mysql.inc on line 172.
    * user warning: Table 'biladibe.flickrusers' doesn't exist query: SELECT u.name, u.uid, flickrusername from flickrusers f INNER JOIN users u ON f.uid = u.uid ORDER BY u.name in /home/web/site/includes/database.mysql.inc on line 172.

user warning: Table 'biladibe.flickrusers' doesn't exist query: SELECT u.name, u.uid, flickrusername from flickrusers f INNER JOIN users u ON f.uid = u.uid ORDER BY u.name in /home/web/site/includes/database.mysql.inc on line 172.

I am using mysql 4.0.24_Debian
PHP 4.3.10-21

Thanks

Comments

JMM’s picture

Title: get error on install » get error on install [SOLUTION]

Maybe is needed to rename some elements on table flickr_users:

Name of table:
old: flickr_users
new: flickrusers

Add a field named flickrusername

An alternative is run this SQL, to get a new and correct table:

CREATE TABLE IF NOT EXISTS `flickrusers` (
`uid` int(10) unsigned NOT NULL default '0',
`nsid` varchar(64) NOT NULL default '',
`identifier` varchar(64) NOT NULL default '',
`flickrusername` varchar(64) NOT NULL default '',
PRIMARY KEY (`uid`)
) TYPE=MyISAM;

Espero que te sirva, and sorry my english :D

José María

Shiny’s picture

Status: Active » Reviewed & tested by the community

i've changed this in head - removed the "DEFAULT" bit.
I use postgresql, so tests of HEAD against mysql are greatly appreciated.

roshjoseph’s picture

Hi, I got the following error after I enabled flickrrippr

user warning: Table 'drupaldb.flickrusers' doesn't exist query: SELECT u.name, u.uid, flickrusername from flickrusers f INNER JOIN users u ON f.uid = u.uid ORDER BY u.name in web\includes\database.mysql.inc on line 172.

I use Ver 5.x of Drupal, MySQL, php and Ver 2.x Apache server.

Any help will be greatly appreciated!

krisvannest’s picture

Did you already have a previous version of flickrripper (before the HEAD patch above) installed on your site, or did you get the error from a new install w/ patch?

winstonford’s picture

I got the same error. The table flickrusers didn't exist in my case because the creation of it errored out on install. Here's the sql command that error'd out:

CREATE TABLE flickrusers ( uid int(11) NOT NULL, flickrusername text NOT NULL, cachejpegs tinyint(1) NOT NULL default 0, flickrusername TEXT NOT NULL, PRIMARY KEY (uid) ) ENGINE=InnoDB

You can see that the column flickrusername is in there twice. I changed the second instance to flickrid:

CREATE TABLE flickrusers ( uid int(11) NOT NULL, flickrusername text NOT NULL, cachejpegs tinyint(1) NOT NULL default 0, flickrid TEXT NOT NULL, PRIMARY KEY (uid) ) ENGINE=InnoDB

I went into the drupal database in phpMyAdmin, pasted in the above sql, clicked GO, and the table was created successfully.

dmuth’s picture

I got these errors as well, on the 5.x-0.1.x-dev release, dated 2008-Jan-04.

-- Doug

Shiny’s picture

Status: Reviewed & tested by the community » Needs review

winstonford: i've made the same change you described, to the mysql install to match the postgres
Testing on mysql welcome - i've been applying patches from mysql users so far, and didn't catch that

if possible, try the drupal6 version instead. The hook_schema was introduced then, meaning the database schema should always be the same on any database, instead of coders writing it out many times over.

Shiny’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.