Log on:
Powered by Elgg

Elgg Installation Support :: Blog :: mod_rewrite

February 07, 2007

Click here for a mod_rewrite primer. The #1 cause of Elgg installation problems is mod_rewrite, which is a part of Apache rather than Elgg. Hopefully this page should help you with any issues you might have. I'll also roll this URL into the INSTALL file for the next Elgg release.

Posted by Elgg Installation Support - Ben Werdmuller


Comments

  1. Thanks for the fast reply. I'll check out the primer and see what I did wrong. I've just installed Serendipity and that was a snap, but only because it gives you the option of turning off mod_rewrite. It also has nothing like the potential of elgg, once it's actually installed. ;-)

    Think I'll take a nap and start fresh in a few hours. I'll let you know how I make out.

    Any thoughts on the SQL syntax errors during db setup? Are these also due to mod_rewrite?

     

    Tim KissaneTim Kissane on Wednesday, 07 February 2007, 12:42 CET # |

  2. I'm not sure about the Postgres SQL syntax errors, to be honest. Would it be possible to post them here?

    Ben WerdmullerBen Werdmuller on Wednesday, 07 February 2007, 12:44 CET # |

  3. Well, let's see how the html handles this... I'll upload the files (yes, I saved them) if this craps out. Here goes...

      This was the page returned upon initial db creation using 0.7 and MySQL5:

     


    (mysql): /*!40101 ALTER DATABASE DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci */  
    Success


    (mysql): CREATE TABLE `elggcontent_flags` ( `ident` int(11) NOT NULL auto_increment, `url` varchar(128) NOT NULL default '', PRIMARY KEY (`ident`), KEY `url` (`url`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggfile_folders` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, folder creator', `files_owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, folder owner (community)', `parent` int(11) NOT NULL default '0' COMMENT '-> file_folders.ident, parent folder', `name` varchar(128) NOT NULL default '', `access` varchar(20) NOT NULL default 'PUBLIC', `handler` varchar(32) NOT NULL default 'elgg', PRIMARY KEY (`ident`), KEY `files_owner` (`files_owner`), KEY `owner` (`owner`), KEY `access` (`access`), KEY `name` (`name`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggfile_metadata` ( `ident` int(11) NOT NULL auto_increment, `name` varchar(255) NOT NULL default '', `value` text NOT NULL, `file_id` int(11) NOT NULL default '0' COMMENT '-> files.ident', PRIMARY KEY (`ident`), KEY `name` (`name`,`file_id`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggfiles` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, file uploader', `files_owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, file owner (community)', `folder` int(11) NOT NULL default '-1' COMMENT '-> file_folders.ident, parent folder', `community` int(11) NOT NULL default '-1' COMMENT 'not used?', `title` varchar(255) NOT NULL default '', `originalname` varchar(255) NOT NULL default '', `description` varchar(255) NOT NULL default '', `location` varchar(255) NOT NULL default '' COMMENT 'file location in dataroot', `access` varchar(20) NOT NULL default 'PUBLIC', `size` int(11) NOT NULL default '0' COMMENT 'bytes', `time_uploaded` int(11) NOT NULL default '0' COMMENT 'unix timestamp', `handler` varchar(32) NOT NULL default 'elgg', PRIMARY KEY (`ident`), KEY `owner` (`owner`,`folder`,`access`), KEY `size` (`size`), KEY `time_uploaded` (`time_uploaded`), KEY `originalname` (`originalname`), KEY `community` (`community`), KEY `files_owner` (`files_owner`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggfriends` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, doing the friending', `friend` int(11) NOT NULL default '0' COMMENT '-> users.ident, being friended', `status` varchar(4) NOT NULL default 'perm' COMMENT 'not used?', PRIMARY KEY (`ident`), KEY `owner` (`owner`), KEY `friend` (`friend`), KEY `status` (`status`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggfriends_requests` ( `ident` INT UNSIGNED NOT NULL AUTO_INCREMENT , `owner` INT NOT NULL COMMENT '-> users.ident, doing the friending', `friend` INT NOT NULL COMMENT '-> users.ident, being friended', PRIMARY KEY (`ident`) , INDEX (`owner`))  
    Success


    (mysql): CREATE TABLE `elgggroup_membership` ( `ident` int(11) NOT NULL auto_increment, `user_id` int(11) NOT NULL default '0' COMMENT '-> users.ident', `group_id` int(11) NOT NULL default '0' COMMENT '-> groups.ident', PRIMARY KEY (`ident`), KEY `user_id` (`user_id`,`group_id`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elgggroups` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident', `name` varchar(128) NOT NULL default '', `access` varchar(20) NOT NULL default 'PUBLIC', PRIMARY KEY (`ident`), KEY `owner` (`owner`,`name`), KEY `access` (`access`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggicons` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident', `filename` varchar(128) NOT NULL default '', `description` varchar(255) NOT NULL default '', PRIMARY KEY (`ident`), KEY `owner` (`owner`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elgginvitations` ( `ident` int(11) NOT NULL auto_increment, `name` varchar(128) NOT NULL default '', `email` varchar(128) NOT NULL default '', `code` varchar(128) NOT NULL default '', `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, sender of invitation', `added` int(11) NOT NULL default '0' COMMENT 'unix timestamp', PRIMARY KEY (`ident`), KEY `code` (`code`), KEY `email` (`email`), KEY `added` (`added`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggpassword_requests` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident', `code` varchar(128) NOT NULL default '', PRIMARY KEY (`ident`), KEY `owner` (`owner`,`code`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggprofile_data` ( `ident` int(10) unsigned NOT NULL auto_increment, `owner` int(10) unsigned NOT NULL default '0' COMMENT '-> users.ident', `access` varchar(20) NOT NULL default 'PUBLIC', `name` varchar(255) NOT NULL default '', `value` text NOT NULL, PRIMARY KEY (`ident`), KEY `owner` (`owner`,`access`,`name`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggtags` ( `ident` int(11) NOT NULL auto_increment, `tag` varchar(128) NOT NULL default '', `tagtype` varchar(20) NOT NULL default '' COMMENT 'type of object the tag links to', `ref` int(11) NOT NULL default '0' COMMENT 'ident of object the tag links to', `access` varchar(20) NOT NULL default 'PUBLIC', `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident', PRIMARY KEY (`ident`), KEY `owner` (`owner`), KEY `tagtype_ref` (`tagtype`,`ref`), FULLTEXT KEY `tag` (`tag`), KEY `tagliteral` (`tag`(20)), KEY `access` (`access`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggtemplate_elements` ( `ident` int(11) NOT NULL auto_increment, `name` varchar(128) NOT NULL default '', `content` text NOT NULL, `template_id` int(11) NOT NULL default '0' COMMENT '-> templates.ident', PRIMARY KEY (`ident`), KEY `name` (`name`,`template_id`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggtemplates` ( `ident` int(11) NOT NULL auto_increment, `name` varchar(128) NOT NULL default '', `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, template creator', `public` enum('yes','no') NOT NULL default 'yes', `shortname` varchar(128) NOT NULL, PRIMARY KEY (`ident`), KEY `name` (`name`,`owner`,`public`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elgguser_flags` ( `ident` int(11) NOT NULL auto_increment, `user_id` int(11) NOT NULL default '0' COMMENT '-> users.ident, user the flag refers to', `flag` varchar(64) NOT NULL default '', `value` varchar(64) NOT NULL default '', PRIMARY KEY (`ident`), KEY `user_id` (`user_id`,`flag`,`value`)) TYPE=MyISAM  
    Success


    (mysql): INSERT INTO `elgguser_flags` VALUES (0,1,'admin','1')  
    Success


    (mysql): CREATE TABLE `elggusers` ( `ident` int(10) unsigned NOT NULL auto_increment, `username` varchar(128) NOT NULL default '' COMMENT 'login name', `password` varchar(32) NOT NULL default '', `email` varchar(128) NOT NULL default '', `name` varchar(128) NOT NULL default '' COMMENT 'descriptive name', `icon` int(11) NOT NULL default '-1' COMMENT '-> icons.ident', `active` enum('yes','no') NOT NULL default 'yes', `alias` varchar(128) NOT NULL default '', `code` varchar(32) NOT NULL default '' COMMENT 'auth value for cookied login', `icon_quota` int(11) NOT NULL default '10' COMMENT 'number of icons', `file_quota` int(11) NOT NULL default '1000000000' COMMENT 'bytes', `template_id` int(11) NOT NULL default '-1' COMMENT '-> templates.ident', `owner` int(11) NOT NULL default '-1' COMMENT '-> users.ident, community owner', `user_type` varchar(128) NOT NULL default 'person' COMMENT 'person, community, etc', `moderation` varchar(4) NOT NULL default 'no' COMMENT 'friendship moderation setting', `last_action` int(10) unsigned NOT NULL default '0' COMMENT 'unix timestamp', `template_name` varchar(128) NOT NULL default 'Default_Template' COMMENT '-> templates.shortname' PRIMARY KEY (`ident`), KEY `username` (`username`,`password`,`name`,`active`), KEY `code` (`code`), KEY `icon` (`icon`), KEY `icon_quota` (`icon_quota`), KEY `file_quota` (`file_quota`), KEY `email` (`email`), KEY `template_id` (`template_id`), KEY `community` (`owner`), KEY `user_type` (`user_type`), KEY `moderation` (`moderation`), KEY `last_action` (`last_action`), FULLTEXT KEY `name` (`name`)) TYPE=MyISAM  
    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 '(`ident`), KEY `username` (`username`,`password`,`name`,`active`), KEY `code` ' at line 1
                ADOConnection._Execute(CREATE TABLE `elggusers` (  `ident` int(10) unsigned NOT NULL auto_increment,  `username` varchar(128) NOT NULL default '' COMME..., false) % line  889, file: adodb.inc.php
          ADOConnection.Execute(CREATE TABLE `elggusers` ( `ident` int(10) unsigned NOT NULL auto_increment, `username` varchar(128) NOT NULL default '' COMME...) % line 38, file: datalib.php
        execute_sql(CREATE TABLE `elggusers` ( `ident` int(10) unsigned NOT NULL auto_increment, `username` varchar(128) NOT NULL default '' COMME...) % line 188, file: datalib.php
      modify_database(/var/www/elgg/0.7/lib/db/mysql.sql) % line 27, file: dbsetup.php
    require_once(/var/www/elgg/0.7/lib/dbsetup.php) % line 50, file: includes.php

    Error


    (mysql): INSERT INTO `elggusers` VALUES (0, 'news', '5f4dcc3b5aa765d61d8327deb882cf99', '', 'News', -1, 'yes', '', '', 10, 10000000, -1, -1, 'person', 'no', 0)  
    1146: Table 'timbury.elggusers' doesn't exist
                ADOConnection._Execute(INSERT INTO `elggusers` VALUES (0, 'news', '5f4dcc3b5aa765d61d8327deb882cf99', '', 'News', -1, 'yes', '', '', 10, 10000000, -1, ..., false) % line  889, file: adodb.inc.php
          ADOConnection.Execute(INSERT INTO `elggusers` VALUES (0, 'news', '5f4dcc3b5aa765d61d8327deb882cf99', '', 'News', -1, 'yes', '', '', 10, 10000000, -1, ...) % line 38, file: datalib.php
        execute_sql(INSERT INTO `elggusers` VALUES (0, 'news', '5f4dcc3b5aa765d61d8327deb882cf99', '', 'News', -1, 'yes', '', '', 10, 10000000, -1, ...) % line 188, file: datalib.php
      modify_database(/var/www/elgg/0.7/lib/db/mysql.sql) % line 27, file: dbsetup.php
    require_once(/var/www/elgg/0.7/lib/dbsetup.php) % line 50, file: includes.php

    Error


    (mysql): CREATE TABLE `elggweblog_comments` ( `ident` int(11) NOT NULL auto_increment, `post_id` int(11) NOT NULL default '0' COMMENT '-> weblog_posts.ident', `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, commenter', `postedname` varchar(128) NOT NULL default '' COMMENT 'displayed name of commenter', `body` text NOT NULL, `posted` int(11) NOT NULL default '0' COMMENT 'unix timestamp', PRIMARY KEY (`ident`), KEY `owner` (`owner`), KEY `posted` (`posted`), KEY `post_id` (`post_id`), KEY `postedname` (`postedname`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggweblog_posts` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, poster', `weblog` int(11) NOT NULL default '-1' COMMENT '-> users.ident, blog being posted into', `icon` int(11) NOT NULL default '-1', `access` varchar(20) NOT NULL default 'PUBLIC', `posted` int(11) NOT NULL default '0' COMMENT 'unix timestamp', `title` text NOT NULL, `body` text NOT NULL, PRIMARY KEY (`ident`), KEY `owner` (`owner`,`access`,`posted`), KEY `community` (`weblog`)) TYPE=MyISAM  
    Success


    (mysql): INSERT INTO `elggweblog_posts` VALUES (0, 1, 1, -1, 'PUBLIC', 1119422380, 'Hello', 'Welcome to this Elgg installation.')  
    Success


    (mysql): CREATE TABLE `elggweblog_watchlist` ( `ident` int(11) NOT NULL auto_increment, `owner` int(11) NOT NULL default '0' COMMENT '-> users.ident, watcher', `weblog_post` int(11) NOT NULL default '0' COMMENT '-> weblog_posts.ident, watched post', PRIMARY KEY (`ident`), KEY `owner` (`owner`), KEY `weblog_post` (`weblog_post`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggdatalists` ( `ident` int(10) unsigned NOT NULL auto_increment, `name` varchar(32) NOT NULL default '', `value` text NOT NULL, PRIMARY KEY (`ident`), KEY `name` (`name`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggusers_alias` ( `ident` int(10) unsigned NOT NULL auto_increment, `installid` varchar(32) NOT NULL default '', `username` varchar(32) NOT NULL default '', `firstname` varchar(64) NOT NULL default '', `lastname` varchar(64) NOT NULL default '', `email` varchar(128) NOT NULL default '', `user_id` int(10) unsigned NOT NULL default 0, PRIMARY KEY (`ident`), KEY `username` (`username`), KEY `installid` (`installid`), KEY `user_id` (`user_id`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggfiles_incoming` ( `ident` int(10) unsigned NOT NULL auto_increment, `installid` varchar(32) NOT NULL default '', `intentiondate` int(11) unsigned NOT NULL default 0, `size` bigint unsigned NOT NULL default 0, `foldername` varchar(128) NOT NULL default '', `user_id` int(10) unsigned NOT NULL default 0, PRIMARY KEY (`ident`), KEY `user_id` (`user_id`)) TYPE=MyISAM  
    Success


    (mysql): CREATE TABLE `elggfeed_posts` ( `ident` int(11) NOT NULL auto_increment, `posted` varchar(64) NOT NULL default '0' COMMENT 'imported human readable date', `added` int(11) NOT NULL default '0' COMMENT 'unix timestamp', `feed` int(11) NOT NULL default '0' COMMENT '-> feeds.ident', `title` text NOT NULL, `body` text NOT NULL, `url` varchar(255) NOT NULL default '' COMMENT 'post-specific or permalink URL', PRIMARY KEY (`ident`), KEY `feed` (`feed`), KEY `posted` (`posted`,`added`), KEY `added` (`added`))  
    Success


    (mysql): CREATE TABLE `elggfeed_subscriptions` ( `ident` int(10) unsigned NOT NULL auto_increment, `user_id` int(10) unsigned NOT NULL default '0' COMMENT '-> users.ident', `feed_id` int(10) unsigned NOT NULL default '0' COMMENT '-> feeds.ident', `autopost` enum('yes','no') NOT NULL default 'no' COMMENT 'whether to insert into subscriber\'s own blog', `autopost_tag` varchar(128) NOT NULL default '' COMMENT 'tag list to add to auto-posts', PRIMARY KEY (`ident`), KEY `feed_id` (`feed_id`), KEY `user_id` (`user_id`), KEY `autopost` (`autopost`))  
    Success


    (mysql): CREATE TABLE `elggfeeds` ( `ident` int(10) unsigned NOT NULL auto_increment, `url` varchar(128) NOT NULL default '' COMMENT 'URL of actual feed', `feedtype` varchar(16) NOT NULL default '' COMMENT 'not used?', `name` text NOT NULL, `tagline` varchar(128) NOT NULL default '', `siteurl` varchar(128) NOT NULL default '' COMMENT 'URL of parent site/page', `last_updated` int(11) NOT NULL default '0' COMMENT 'unix timestamp', PRIMARY KEY (`ident`), KEY `url` (`url`,`feedtype`), KEY `last_updates` (`last_updated`), KEY `siteurl` (`siteurl`), KEY `tagline` (`tagline`))  
    Success


    (mysql): CREATE TABLE `elggmessages` ( `ident` int(11) NOT NULL auto_increment, `title` text NOT NULL default '', `body` text NOT NULL default '', `from_id` int(11) NOT NULL, `to_id` int(11) NOT NULL, `posted` int(11) NOT NULL, `status` enum('read','unread') NOT NULL default 'unread', PRIMARY KEY (`ident`), KEY `from` (`from_id`,`to_id`,`posted`)) TYPE=MyISAM  
    Success


    (mysql): SHOW TABLES  
    Error
    Error: Main databases NOT set up successfully

     

    ===========================================

     

      This was the result of initializing Postgres 8.1 with elgg 0.7: 

     


    (postgres7): CREATE TABLE elggcontent_flags ( ident SERIAL PRIMARY KEY, url varchar(128) NOT NULL default '')  
    Success


    (postgres7): CREATE INDEX elggcontent_flags_url_idx ON elggcontent_flags (url)  
    Success


    (postgres7): CREATE TABLE elggfile_folders ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default '0', files_owner integer NOT NULL default '0', parent integer NOT NULL default '0', name varchar(128) NOT NULL default '', access varchar(20) NOT NULL default 'PUBLIC', handler varchar(32) NOT NULL default 'elgg')  
    Success


    (postgres7): CREATE INDEX elggfile_folders_files_owner_idx ON elggfile_folders (files_owner)  
    Success


    (postgres7): CREATE INDEX elggfile_folders_owner_idx ON elggfile_folders (owner)  
    Success


    (postgres7): CREATE INDEX elggfile_folders_access_idx ON elggfile_folders (access)  
    Success


    (postgres7): CREATE INDEX elggfile_folders_name_idx ON elggfile_folders (name)  
    Success


    (postgres7): CREATE TABLE elggfile_metadata ( ident SERIAL PRIMARY KEY, name varchar(255) NOT NULL default '', value text NOT NULL, file_id integer NOT NULL default '0')  
    Success


    (postgres7): CREATE INDEX elggfile_metadata_name_idx ON elggfile_metadata (name,file_id)  
    Success


    (postgres7): CREATE TABLE elggfiles ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default '0', files_owner integer NOT NULL default '0', folder integer NOT NULL default '-1', community integer NOT NULL default '-1', title varchar(255) NOT NULL default '', originalname varchar(255) NOT NULL default '', description varchar(255) NOT NULL default '', location varchar(255) NOT NULL default '', access varchar(20) NOT NULL default 'PUBLIC', size integer NOT NULL default '0', time_uploaded integer NOT NULL default '0', handler varchar(32) NOT NULL default 'elgg')  
    Success


    (postgres7): CREATE INDEX elggfiles_owner_idx ON elggfiles (owner,folder,access)  
    Success


    (postgres7): CREATE INDEX elggfiles_size_idx ON elggfiles (size)  
    Success


    (postgres7): CREATE INDEX elggfiles_time_uploaded_idx ON elggfiles (time_uploaded)  
    Success


    (postgres7): CREATE INDEX elggfiles_originalname_idx ON elggfiles (originalname)  
    Success


    (postgres7): CREATE INDEX elggfiles_community_idx ON elggfiles (community)  
    Success


    (postgres7): CREATE INDEX elggfiles_files_owner_idx ON elggfiles (files_owner)  
    Success


    (postgres7): CREATE TABLE elggfriends ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default '0', friend integer NOT NULL default '0', status varchar(4) NOT NULL default 'perm')  
    Success


    (postgres7): CREATE INDEX elggfriends_owner_idx ON elggfriends (owner)  
    Success


    (postgres7): CREATE INDEX elggfriends_friend_idx ON elggfriends (friend)  
    Success


    (postgres7): CREATE INDEX elggfriends_status_idx ON elggfriends (status)  
    Success


    (postgres7): CREATE TABLE elggfriends_requests ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default 0, friend integer NOT NULL default 0)  
    Success


    (postgres7): CREATE INDEX elggfriends_requests_owner_idx ON elggfriends_requests (owner)  
    Success


    (postgres7): CREATE TABLE elgggroup_membership ( ident SERIAL PRIMARY KEY, user_id integer NOT NULL default '0', group_id integer NOT NULL default '0')  
    Success


    (postgres7): CREATE INDEX elgggroup_membership_user_id_idx ON elgggroup_membership (user_id,group_id)  
    Success


    (postgres7): CREATE TABLE elgggroups ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default '0', name varchar(128) NOT NULL default '', access varchar(20) NOT NULL default 'PUBLIC')  
    Success


    (postgres7): CREATE INDEX elgggroups_owner_idx ON elgggroups (owner,name)  
    Success


    (postgres7): CREATE INDEX elgggroups_access_idx ON elgggroups (access)  
    Success


    (postgres7): CREATE TABLE elggicons ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default '0', filename varchar(128) NOT NULL default '', description varchar(255) NOT NULL default '')  
    Success


    (postgres7): CREATE INDEX elggicons_owner_idx ON elggicons (owner)  
    Success


    (postgres7): CREATE TABLE elgginvitations ( ident SERIAL PRIMARY KEY, name varchar(128) NOT NULL default '', email varchar(128) NOT NULL default '', code varchar(128) NOT NULL default '', owner integer NOT NULL default '0', added integer NOT NULL default '0')  
    Success


    (postgres7): CREATE INDEX elgginvitations_code_idx ON elgginvitations (code)  
    Success


    (postgres7): CREATE INDEX elgginvitations_email_idx ON elgginvitations (email)  
    Success


    (postgres7): CREATE INDEX elgginvitations_added_idx ON elgginvitations (added)  
    Success


    (postgres7): CREATE TABLE elggpassword_requests ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default '0', code varchar(128) NOT NULL default '')  
    Success


    (postgres7): CREATE INDEX elggpassword_requests_owner_idx ON elggpassword_requests (owner,code)  
    Success


    (postgres7): CREATE TABLE elggprofile_data ( ident SERIAL PRIMARY KEY, owner integer NOT NULL default '0', access varchar(20) NOT NULL default 'PUBLIC', name varchar(255) NOT NULL default '', value text NOT NULL)  
    Success


    (postgres7): CREATE INDEX elggprofile_data_owner_idx ON elggprofile_data (owner,access,name)  
    Success


    (postgres7): CREATE TABLE elggtags ( ident SERIAL PRIMARY KEY, tag varchar(128) NOT NULL default '', tagtype varchar(20) NOT NULL default '', ref integer NOT NULL default '0', access varchar(20) NOT NULL default 'PUBLIC', owner integer NOT NULL default '0')  
    Success


    (postgres7): CREATE INDEX elggtags_owner_idx ON elggtags (owner)  
    Success


    (postgres7): CREATE INDEX elggtags_tagtype_ref_idx ON elggtags (tagtype,ref)  
    Success


    (postgres7): CREATE INDEX elggtags_tag_idx ON elggtags (tag)  
    Success


    (postgres7): CREATE INDEX elggtags_access_idx ON elggtags (access)  
    Success


    (postgres7): CREATE TABLE elggtemplate_elements ( ident SERIAL PRIMARY KEY, name varchar(128) NOT NULL default '', content text NOT NULL, template_id integer NOT NULL default '0')  
    Success


    (postgres7): CREATE INDEX elggtemplate_elements_name_idx ON elggtemplate_elements (name,template_id)  
    Success


    (postgres7): CREATE TABLE elggtemplates ( ident SERIAL PRIMARY KEY, name varchar(128) NOT NULL default '', owner integer NOT NULL default '0', public varchar(3) CHECK (public IN ('yes','no')) NOT NULL default 'yes', shortname varchar(128) NOT NULL,)  

    Warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near ")" at character 241 in /var/www/elgg/0.7/lib/adodb/drivers/adodb-postgres7.inc.php on line 115
    -1: ERROR: syntax error at or near ")" at character 241
                ADOConnection._Execute(CREATE TABLE elggtemplates (  ident SERIAL PRIMARY KEY,  name varchar(128) NOT NULL default '',  owner integer NOT NULL default ..., false) % line  889, file: adodb.inc.php
          ADOConnection.Execute(CREATE TABLE elggtemplates ( ident SERIAL PRIMARY KEY, name varchar(128) NOT NULL default '', owner integer NOT NULL default ...) % line 38, file: datalib.php
        execute_sql(CREATE TABLE elggtemplates ( ident SERIAL PRIMARY KEY, name varchar(128) NOT NULL default '', owner integer NOT NULL default ...) % line 188, file: datalib.php
      modify_database(/var/www/elgg/0.7/lib/db/postgres7.sql) % line 27, file: dbsetup.php
    require_once(/var/www/elgg/0.7/lib/dbsetup.php) % line 50, file: includes.php


    Fatal error: postgres7 error: [-1: ERROR: syntax error at or near ")" at character 241] in EXECUTE("CREATE TABLE elggtemplates ( ident SERIAL PRIMARY KEY, name varchar(128) NOT NULL default '', owner integer NOT NULL default '0', public varchar(3) CHECK (public IN ('yes','no')) NOT NULL default 'yes', shortname varchar(128) NOT NULL,) ") in /var/www/elgg/0.7/lib/adodb/adodb-errorhandler.inc.php on line 77

     ====================================

    I thought this might have been something silly, like the comma in the final string, 

     " shortname varchar(128) NOT NULL,) " but I don't know enough about

    SQL, PHP, or the structure of elgg yet, to actually find this and correct it (if

    it is even a problem)...

    Thanks for checking this out. 

     

    default user iconGuest on Wednesday, 07 February 2007, 13:30 CET # |

  4. Okay - I've now worked out what the issue is, and I've checked in a new version of /lib/db/mysql.sql.

    Click here to download the replacement file.

    Ben WerdmullerBen Werdmuller on Wednesday, 07 February 2007, 17:23 CET # |

  5. Thanks, this fixes the problem on MySQL. Btw, I *did* also catch an error in my mod_rewrite setup. AllowOverides was set to 'None', when it should have been 'All' for the elgg directory.

    I'm going to try this with PostgreSQL 8.1 and see if it helps there as well - or is there a separate file for that? Perhaps I'll have a peek at the other files in lib/db...

    Thanks for a prompt response and fix. Perhaps I'll be able to use elgg after all. ;-) 

    It really is a nice package. 

    Tim KissaneTim Kissane on Wednesday, 07 February 2007, 18:33 CET # |

  6. that didn't fix anything for me.  please help!

    default user iconIvan on Tuesday, 13 March 2007, 22:07 CET # |

  7. The first page of the initial db creation went smoothly, but on the second page I get two lines of 'Error' and a continue button which loads the same page again.  How can I get around this?

    default user iconGuest on Tuesday, 20 March 2007, 10:41 CET # |

  8. Interesting comments.. :D http://www.j2ack.org/imparare

    default user iconGuest on Sunday, 15 April 2007, 08:06 CEST # |

You must be logged in to post a comment.