ALTER TABLE Events ADD INDEX lookuppt ( person_table);
--# speeding up lookups.
-ALTER TABLE Events ADD INDEX lookup_when( person_id, event_id );
+ALTER TABLE Events ADD INDEX lookup_when( person_id, event_when );
ALTER TABLE Events add index lookup_event_when (event_when);
ALTER TABLE Events add index lookup_action (action);
ALTER TABLE Person ADD COLUMN phone_mobile varchar(32) NOT NULL DEFAULT '';
ALTER TABLE Person ADD COLUMN phone_direct varchar(32) NOT NULL DEFAULT '';
+ALTER TABLE Person ADD COLUMN honor varchar(32) NOT NULL DEFAULT '';
# old mysql
alter table Person change column active active int(11) NOT NULL DEFAULT 1 ;
ALTER TABLE Projects ADD COLUMN open_by int(11) NOT NULL default '0';
ALTER TABLE Projects ADD COLUMN updated_dt DATETIME NOT NULL;
-# these should be removed, as they are code specific..
+-- these should be removed, as they are code specific..
ALTER TABLE Projects ADD COLUMN countries varchar(128) NOT NULL DEFAULT '';
ALTER TABLE Projects ADD COLUMN languages varchar(128) NOT NULL DEFAULT '';
ALTER TABLE Projects ADD COLUMN agency_id int(11) NOT NULL DEFAULT 0 ;
ALTER TABLE Projects ADD INDEX plookup (code);
-#-- we duplicate office_id and company_id here...
-#-- not sure if we should keep doing that in the new design...
-#-- we should improve our links code to handle this..
+-- we duplicate office_id and company_id here...
+-- not sure if we should keep doing that in the new design...
+-- we should improve our links code to handle this..
CREATE TABLE ProjectDirectory (
ALTER TABLE Images ADD COLUMN descript TEXT DEFAULT '' NOT NULL;
ALTER TABLE Images ADD COLUMN title VARCHAR(128) DEFAULT '' NOT NULL;
-ALTER TABLE Images ALTER COLUMN mimetype mimetype varchar(128) NOT NULL default '';
+ALTER TABLE Images CHANGE COLUMN mimetype mimetype varchar(128) NOT NULL default '';
+-- postgres
+ALTER TABLE Images ALTER COLUMN mimetype TYPE varchar(128) ;
ALTER TABLE Images ADD INDEX lookup(ontable, onid);
ALTER TABLE Images ADD INDEX lookupc(created, ontable, onid);
-#// old core image type - merged into enum.
+--// old core image type - merged into enum.
DROP TABLE core_image_type;
alter table core_enum ADD INDEX lookup(seqid, active, name, etype);
UPDATE core_enum SET display_name = name WHERE display_name = '';
+ALTER TABLE core_enum ADD COLUMN is_system_enum INT(2) NOT NULL DEFAULT 0;