<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\Migrations\AbstractMigration;
use Doctrine\DBAL\Schema\Schema;
/**
* Auto-generated Migration: Please modify to your needs!
*/
class Version20150522115517 extends AbstractMigration
{
public function getDescription(): string
{
return '';
}
/**
* @param Schema $schema
*/
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('RENAME TABLE ArchaeologyContextNatures TO archaeology_context_nature');
$this->addSql('RENAME TABLE ArchaeologyPeriods TO archaeology_period');
$this->addSql('RENAME TABLE ArchaeologyRecoveryMethods TO archaeology_recovery_method');
$this->addSql('RENAME TABLE ArchaeologySiteContextDetails TO archaeology_site_context_detail');
$this->addSql('RENAME TABLE ArchaeologySiteContexts TO archaeology_site_context');
$this->addSql('RENAME TABLE CoinsReferences TO coin_reference');
$this->addSql('RENAME TABLE Coins TO coin');
$this->addSql('RENAME TABLE Conditions TO `condition`');
$this->addSql('RENAME TABLE ContainerForms TO container_form');
$this->addSql('RENAME TABLE Containers TO container');
$this->addSql('RENAME TABLE ContainerSherds TO container_sherd');
$this->addSql('RENAME TABLE Countries TO country');
$this->addSql('RENAME TABLE Denominations TO denomination');
$this->addSql('RENAME TABLE CoinsDenominations TO coin_denomination');
$this->addSql('RENAME TABLE DiscoveryLandUses TO discovery_land_use');
$this->addSql('RENAME TABLE DiscoveryMethods TO discovery_method');
$this->addSql('RENAME TABLE FindSpotLocationDetails TO find_spot_location_detail');
$this->addSql('RENAME TABLE HideFroms TO hide_from');
$this->addSql('RENAME TABLE HideWhats TO hide_what');
$this->addSql('RENAME TABLE HoardImages TO hoard_image');
$this->addSql('RENAME TABLE HoardsReferences TO hoard_reference');
$this->addSql('RENAME TABLE Hoards TO hoard');
$this->addSql('RENAME TABLE HoardTypes TO hoard_type');
$this->addSql('RENAME TABLE Layers TO layer');
$this->addSql('RENAME TABLE Materials TO material');
$this->addSql('RENAME TABLE Mints TO mint');
$this->addSql('RENAME TABLE CoinsMints TO coin_mint');
$this->addSql('RENAME TABLE ObjectsReferences TO object_reference');
$this->addSql('RENAME TABLE Objects TO object');
$this->addSql('RENAME TABLE Periods TO period');
$this->addSql('RENAME TABLE Persons TO person');
$this->addSql('RENAME TABLE CoinsPersons TO coin_person');
$this->addSql('RENAME TABLE `References` TO reference');
$this->addSql('RENAME TABLE ReferenceTypes TO reference_type');
$this->addSql('RENAME TABLE Ratings TO rating');
$this->addSql('RENAME TABLE Reigns TO reign');
$this->addSql('RENAME TABLE CoinsReigns TO coin_reign');
$this->addSql('RENAME TABLE Reports TO report');
$this->addSql('RENAME TABLE Status TO status');
$this->addSql('RENAME TABLE Users TO user');
$this->addSql('RENAME TABLE UsersCountries TO user_country');
$this->addSql('RENAME TABLE UsersHoards TO user_hoard');
$this->addSql('RENAME TABLE Aspects TO aspect');
$this->addSql('RENAME TABLE CoinsAspects TO coin_aspect');
$this->addSql('RENAME TABLE AdditionalFields TO additional_field');
$this->addSql('RENAME TABLE CoinsAdditionalFields TO coin_additional_field');
$this->addSql('RENAME TABLE Provinces TO province');
$this->addSql('CREATE TABLE image (id INTEGER NOT NULL AUTO_INCREMENT, filename VARCHAR(255), creation_date TIMESTAMP DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (id)) ENGINE=InnoDB DEFAULT CHARSET=utf8');
$this->addSql('ALTER TABLE archaeology_context_nature CHANGE ArchaeologyContextNatureID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE archaeology_period CHANGE ArchaeologyPeriodID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE archaeology_recovery_method CHANGE ArchaeologyRecoveryMethodID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE archaeology_site_context_detail CHANGE ArchaeologySiteContextDetailID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE archaeology_site_context CHANGE ArchaeologySiteContextID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin_reference CHANGE CoinReferenceID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin CHANGE CoinID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE `condition` CHANGE ConditionID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE container_form CHANGE ContainerFormID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE container CHANGE ContainerID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE container_sherd CHANGE ContainerSherdID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE country CHANGE CountryID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE denomination CHANGE DenominationID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE discovery_land_use CHANGE DiscoveryLandUseID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE discovery_method CHANGE DiscoveryMethodID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE find_spot_location_detail CHANGE FindSpotLocationDetailID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB') ;
$this->addSql('ALTER TABLE hide_from CHANGE HideFromID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE hide_what CHANGE HideWhatID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE hoard_image CHANGE HoardImageID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE hoard_reference CHANGE HoardReferenceID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE hoard CHANGE HoardID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE hoard_type CHANGE HoardTypeID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE layer CHANGE LayerID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE material CHANGE MaterialID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE mint CHANGE MintID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE object_reference CHANGE ObjectReferenceID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE object CHANGE ObjectID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE period CHANGE PeriodID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE person CHANGE PersonID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE reference CHANGE ReferenceID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE reference_type CHANGE ReferenceTypeID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE rating CHANGE RatingID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE reign CHANGE ReignID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE report CHANGE ReportID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE status CHANGE StatusID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE user CHANGE UserID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE user_country CHANGE UserCountryID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE user_hoard CHANGE UserHoardID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE aspect CHANGE AspectID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin_aspect CHANGE CoinAspectID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE additional_field CHANGE AdditionalFieldID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin_additional_field CHANGE CoinCoinsAdditionalFieldD id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin_denomination CHANGE CoinDenominationID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin_person CHANGE CoinPersonID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin_reign CHANGE CoinReignID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE coin_mint CHANGE CoinMintID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ') ;
$this->addSql('ALTER TABLE province CHANGE ProvinceID id int(11) NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY(id), ENGINE=InnoDB ');
// archaeology_context_nature table
$this->addSql('ALTER TABLE archaeology_context_nature CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ArchaeologyContextNature archaeology_context_nature VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// archaeology_period table
$this->addSql('ALTER TABLE archaeology_period CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ArchaeologyPeriod archaeology_period VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// archaeology_recovery_method table
$this->addSql('ALTER TABLE archaeology_recovery_method CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ArchaeologyRecoveryMethod archaeology_recovery_method VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// archaeology_site_context table
$this->addSql('ALTER TABLE archaeology_site_context CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ArchaeologySiteContext archaeology_site_context VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// archaeology_site_context_detail table
$this->addSql('ALTER TABLE archaeology_site_context_detail CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ArchaeologySiteContextDetail archaeology_site_context_detail VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// coin table
$this->addSql('ALTER TABLE coin CHANGE HoardID hoard_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE PeriodID period_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE StartingDate starting_date INT( 11 ) NULL DEFAULT NULL ,
CHANGE EndingDate ending_date INT( 11 ) NULL DEFAULT NULL ,
CHANGE DateText date_text VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE ObverseMintMark obverse_mint_mark VARCHAR(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE ObverseDescription obverse_description LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE ReverseInscription reverse_inscription VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE ReverseMintMark reverse_mint_mark VARCHAR(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE ReverseDescription reverse_description LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Weight weight DOUBLE NULL DEFAULT NULL,
CHANGE Quantity quantity INT(11) NULL DEFAULT \'1\',
CHANGE Issue issue INT( 11 ) NULL DEFAULT NULL ,
CHANGE Officina officina INT( 11 ) NULL DEFAULT NULL ,
CHANGE ObverseInscription obverse_inscription VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Diameter diameter DOUBLE NULL DEFAULT NULL ,
CHANGE Axis axis INT( 11 ) NULL DEFAULT NULL ,
CHANGE ContainerID container_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE LayerID layer_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE ConditionID condition_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Imitation imitation TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE LatestCoin latest_coin TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE Intruder intruder TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE ToCheck to_check TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
//coin_reference table
$this->addSql('ALTER TABLE coin_reference CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE CoinID coin_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE PublicationID reference_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Reference reference VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE ThisSpecimen this_specimen TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// condition table
$this->addSql('ALTER TABLE `condition` CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE `Condition` `condition` VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Grade grade INT( 11 ) NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// container table
$this->addSql('ALTER TABLE container CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE HoardID hoard_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Container container VARCHAR( 100 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE MaterialID material_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE ContainerSherdID container_sherd_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE ContainerFormID container_form_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// container_form table
$this->addSql('ALTER TABLE container_form CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ContainerForm container_form VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// container_sherd table
$this->addSql('ALTER TABLE container_sherd CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ContainerSherd container_sherd VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// country table
$this->addSql('ALTER TABLE country CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Country country VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// denomination table
$this->addSql('ALTER TABLE denomination CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Denomination denomination VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE MaterialID material_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// discovery_land_use table
$this->addSql('ALTER TABLE discovery_land_use CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE DiscoveryLandUse discovery_land_use VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// discovery_method table
$this->addSql('ALTER TABLE discovery_method CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE DiscoveryMethod discovery_method VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// find_spot_location_detail table
$this->addSql('ALTER TABLE find_spot_location_detail CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE FindSpotLocationDetail find_spot_location_detail VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// hide_from table
$this->addSql('ALTER TABLE hide_from CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE HideFrom hide_from VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// hide_what table
$this->addSql('ALTER TABLE hide_what CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE HideWhat hide_what VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// hoard table changes
$this->addSql('ALTER TABLE hoard CHANGE HoardTypeID hoard_type_id INT( 11 ) NULL DEFAULT \'1\'') ;
$this->addSql('ALTER TABLE hoard CHANGE FindspotName find_spot_name VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE FindspotOtherNames find_spot_other_names VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE Address address VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE City city VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE County county VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE Region region VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE CountryID country_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ProvinceID province_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE FindSpotLattitude find_spot_lattitude DOUBLE NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE FindSpotLongitude find_spot_longitude DOUBLE NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE FindSpotAltitude find_spot_altitude DOUBLE NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE FindspotLocationDetailID find_spot_location_detail_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE FindspotComment find_spot_comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryDay1 discovery_day1 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryMonth1 discovery_month1 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryYear1 discovery_year1 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryDay2 discovery_day2 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryMonth2 discovery_month2 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryYear2 discovery_year2 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE OpeningYear1 opening_year1 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE OpeningYear2 opening_year2 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ClosingYear1 closing_year1 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ClosingYear2 closing_year2 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ClosingReign1ID closing_reign1_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ClosingReign2ID closing_reign2_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE TerminalYear1 terminal_year1 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE TerminalYear2 terminal_year2 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE Reference reference_string LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE Description description VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ToEnterAtCoinLevel to_enter_at_coin_level TINYINT( 1 ) NULL DEFAULT \'0\'') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryMethodID discovery_method_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryLandUseID discovery_land_use_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryDepth discovery_depth VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE Owner owner VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE Finder finder VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE DiscoveryComment discovery_comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyRecoveryMethodID archaeology_recovery_method_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologySiteContextID archaeology_site_context_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologySiteContextDetailID archaeology_site_context_detail_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyPeriodID archaeology_period_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyStartYear archaeology_start_year INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyEndYear archaeology_end_year INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyNaturalFeatures archaeology_natural_features VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologySiteComment archaeology_site_comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyContextNatureID archaeology_context_nature_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyContextDate1 archaeology_context_date1 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyContextDate2 archaeology_context_date2 INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyAssociatedFeatures archaeology_associated_features LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyEndPeriodID archaeology_end_period_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE FindSpotRatingID find_spot_rating_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ArchaeologyRatingID archaeology_rating_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE ContextualRatingID contextual_rating_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE RatingID rating_id INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE RatingComment rating_comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard CHANGE HideWhatID hide_what_id INT( 11 ) NULL DEFAULT NULL') ;
$this->addSql('ALTER TABLE hoard CHANGE HideFromID hide_from_id INT( 11 ) NOT NULL DEFAULT \'1\'') ;
$this->addSql('ALTER TABLE hoard CHANGE ValidatedByUser validated_by_user TINYINT( 1 ) NULL DEFAULT \'0\'') ;
$this->addSql('ALTER TABLE hoard CHANGE ValidatedByAdmin validated_by_admin TINYINT( 1 ) NULL DEFAULT \'0\'') ;
$this->addSql('ALTER TABLE hoard CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ') ;
$this->addSql('ALTER TABLE hoard ADD modified_date TIMESTAMP NULL') ;
$this->addSql('ALTER TABLE hoard ADD created_by INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard ADD modified_by INT( 11 ) NULL DEFAULT NULL ') ;
$this->addSql('ALTER TABLE hoard ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
$this->addSql('ALTER TABLE hoard ADD deletedAt DATETIME NULL DEFAULT NULL') ;
// hoard constraints
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT hoard_type_id FOREIGN KEY (hoard_type_id) references hoard_type(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT country FOREIGN KEY (country_id) references country(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT find_spot_location_detail FOREIGN KEY (find_spot_location_detail_id ) references find_spot_location_detail(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT closing_reign1 FOREIGN KEY (closing_reign1_id) references reign(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT closing_reign2 FOREIGN KEY (closing_reign2_id) references reign(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT discovery_method FOREIGN KEY (discovery_method_id) references discovery_method(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT discovery_land_use FOREIGN KEY (discovery_land_use_id) references discovery_land_use(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT archaeology_recovery_method FOREIGN KEY (archaeology_recovery_method_id) references archaeology_recovery_method(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT archaeology_site_context FOREIGN KEY (archaeology_site_context_id) references archaeology_site_context(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT archaeology_site_context_detail FOREIGN KEY (archaeology_site_context_detail_id) references archaeology_site_context_detail(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT archaeology_period FOREIGN KEY (archaeology_period_id) references archaeology_period(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT archaeology_context_nature FOREIGN KEY (archaeology_context_nature_id) references archaeology_context_nature(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT archaeology_end_period FOREIGN KEY (archaeology_end_period_id) references archaeology_period(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT find_spot_rating FOREIGN KEY (find_spot_rating_id) references rating(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT archaeology_rating FOREIGN KEY (archaeology_rating_id) references rating(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT contextual_rating FOREIGN KEY (contextual_rating_id) references rating(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT rating FOREIGN KEY (rating_id) references rating(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT hide_what FOREIGN KEY (hide_what_id) references hide_what(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT hide_from FOREIGN KEY (hide_from_id) references hide_from(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT created FOREIGN KEY (created_by) references user(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
$this->addSql('ALTER TABLE hoard ADD CONSTRAINT modified FOREIGN KEY (modified_by) references user(id) ON DELETE NO ACTION ON UPDATE NO ACTION') ;
// hoard_image table
$this->addSql('ALTER TABLE hoard_image CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE HoardID hoard_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD image_id INT( 11 ) NULL DEFAULT NULL ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// hoard_reference table
$this->addSql('ALTER TABLE hoard_reference CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE HoardID hoard_id INT( 11 ) NOT NULL ,
CHANGE ReferenceID reference_id INT( 11 ) NOT NULL ,
CHANGE Reference reference VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// hoard_type table
$this->addSql('ALTER TABLE hoard_type CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE HoardType hoard_type VARCHAR( 50 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// image table
$this->addSql('ALTER TABLE image CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE filename file_name VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE creation_date creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// layer table
$this->addSql('ALTER TABLE layer CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ContainerID container_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Layer layer VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// material table
$this->addSql('ALTER TABLE material CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Material material VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// mint table
$this->addSql('ALTER TABLE mint CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Mint mint VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE PeriodID period_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Lattitude lattitude DOUBLE NULL DEFAULT NULL ,
CHANGE Longitude longitude DOUBLE NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// object table
$this->addSql('ALTER TABLE object CHANGE id id INT(11) NOT NULL AUTO_INCREMENT,
CHANGE HoardID hoard_id INT(11) NOT NULL,
CHANGE ContainerID container_id INT(11) NULL DEFAULT NULL,
CHANGE Object object VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE MaterialID material_id INT(11) NULL DEFAULT NULL,
CHANGE Description description LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Quantity quantity INT(11) NULL DEFAULT NULL,
CHANGE ProductionPlace production_place VARCHAR(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Weight weight DOUBLE NULL DEFAULT NULL,
CHANGE DimensionLengthCm dimension_length_cm INT(11) NULL DEFAULT NULL,
CHANGE DimensionWidthCm dimension_width_cm INT(11) NULL DEFAULT NULL,
CHANGE DimensionDiameterCm dimension_diameter_cm INT(11) NULL DEFAULT NULL,
CHANGE StartYear start_year INT(11) NULL DEFAULT NULL,
CHANGE EndYear end_year INT(11) NULL DEFAULT NULL,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// object_reference table
$this->addSql('ALTER TABLE object_reference CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ObjectID object_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE ReferenceID reference_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Reference reference VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE ThisObject this_object TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date DATETIME NULL DEFAULT NULL,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// period table
$this->addSql('ALTER TABLE period CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Period period VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE PersonControlName person_control_name VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// person table
$this->addSql('ALTER TABLE person CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Period1ID period1_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Period2ID period2_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Person person VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Title title VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE StartDate start_date INT( 11 ) NULL DEFAULT NULL ,
CHANGE EndDate end_date INT( 11 ) NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// reference table
$this->addSql('ALTER TABLE reference CHANGE id id INT(11) NOT NULL AUTO_INCREMENT,
CHANGE ReferenceTypeID reference_type_id INT(11) NULL DEFAULT NULL,
CHANGE Authors authors VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Editors editors VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Title title VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE TitleEdition title_edition VARCHAR(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Volume volume VARCHAR(30) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Place place VARCHAR(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Year year INT(11) NULL DEFAULT NULL,
CHANGE Pages pages VARCHAR(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Abbreviation abbreviation VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE URI1 uri1 VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE URI1AccessionDate uri1_accession_date DATETIME NULL DEFAULT NULL,
CHANGE URI2 uri2 VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE URI2AccessionDate uri2_accession_date DATETIME NULL DEFAULT NULL,
CHANGE FullyEntered fully_entered TINYINT(1) NULL DEFAULT \'0\',
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\',
ADD deletedAt DATETIME NULL DEFAULT NULL') ;
// reference_type table
$this->addSql('ALTER TABLE reference_type CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE ReferenceType reference_type VARCHAR( 50 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// rating table
$this->addSql('ALTER TABLE rating CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Rating rating INT( 11 ) NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// reign table
$this->addSql('ALTER TABLE reign CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Period1ID period1_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Period2ID period2_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE Reign reign VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL ,
CHANGE StartDate start_date INT( 11 ) NULL DEFAULT NULL ,
CHANGE EndDate end_date INT( 11 ) NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// report table
$this->addSql('ALTER TABLE report CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE HoardID hoard_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE URI uri VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Description description LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// status table
$this->addSql('ALTER TABLE status CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Status status VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Description description VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// user table
$this->addSql('ALTER TABLE user CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Login login VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Password password VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Title title VARCHAR( 11 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE FirstName first_name VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE LastName last_name VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Institution institution VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Administrator administrator TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// user_country table
$this->addSql('ALTER TABLE user_country CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE UserID user_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE CountryID country_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE CanEdit can_edit TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// user_hoard table
$this->addSql('ALTER TABLE user_hoard CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE UserID user_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE HoardID hoard_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE CanEdit can_edit TINYINT( 1 ) NULL DEFAULT \'0\',
CHANGE Comment comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// coin_denomination table
$this->addSql('ALTER TABLE coin_denomination CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE CoinId coin_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE DenominationId denomination_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP');
// coin_mint table
$this->addSql('ALTER TABLE coin_mint CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE CoinId coin_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE MintId mint_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP');
// coin_person table
$this->addSql('ALTER TABLE coin_person CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE CoinId coin_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE PersonId person_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP');
// coin_reign table
$this->addSql('ALTER TABLE coin_reign CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE CoinId coin_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE ReignId reign_id INT( 11 ) NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP');
// province table
$this->addSql('ALTER TABLE province CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Province province VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Comment comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'');
// aspect table
$this->addSql('ALTER TABLE aspect CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT ,
CHANGE Aspect aspect VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Description description LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Note comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE SortValue sort_value DOUBLE NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// coin_aspect table
$this->addSql('ALTER TABLE coin_aspect CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT,
CHANGE CoinID coin_id INT( 11 ) NULL DEFAULT NULL,
CHANGE AspectID aspect_id INT( 11 ) NULL DEFAULT NULL,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// additional_field Table
$this->addSql('ALTER TABLE additional_field CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT,
CHANGE AdditionalField additional_field VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE Description description LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE URI1 uri1 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE URI2 uri2 VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE Note comment LONGTEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL ,
CHANGE SortValue sort_value DOUBLE NULL DEFAULT NULL ,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// coin_additional_field
$this->addSql('ALTER TABLE coin_additional_field CHANGE id id INT( 11 ) NOT NULL AUTO_INCREMENT,
CHANGE CoinId coin_id INT( 11 ) NULL DEFAULT NULL,
CHANGE AdditionalFieldID additional_field_id INT( 11 ) NULL DEFAULT NULL,
CHANGE Note comment VARCHAR( 255 ) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL,
CHANGE CreationDate creation_date TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ,
ADD modified_date TIMESTAMP NULL,
ADD created_by INT( 11 ) NULL DEFAULT NULL,
ADD modified_by INT( 11 ) NULL DEFAULT NULL,
ADD deleted TINYINT( 1 ) NULL DEFAULT \'0\'') ;
// create view to aggregrate the number of coins in a hoard (used by Search form)
$this->addSql('CREATE VIEW hoard_coin_count AS SELECT hoard_id, sum(quantity) AS coin_count from coin group by hoard_id') ;
}
/**
* @param Schema $schema
*/
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->abortIf($this->connection->getDatabasePlatform()->getName() != 'mysql', 'Migration can only be executed safely on \'mysql\'.');
// ignored for now, assumed a reversal of version 0 is not needed
}
}