<?php

class m170714_130852_create_report_archive_table extends MyDbMigration
{
	public function up()
	{
		$this->createNonExistingTable('report_archive',
			array(
				'ID' => 'pk',
				'UserID' => 'BIGINT(20) NOT NULL',
				'GroupID' => 'BIGINT(20) NOT NULL',
				'CreationTime' => 'DATETIME NOT NULL',
				'MinExtcode' => 'CHAR(250) NOT NULL',
				'MaxExtcode' => 'CHAR(250) NOT NULL',
				'Document' => 'MEDIUMBLOB NOT NULL',
			),
			'ENGINE=MyISAM'
		);
	}

	public function down()
	{
		$this->dropTable('report_archive');
	}

	/*
	// Use safeUp/safeDown to do migration with transaction
	public function safeUp()
	{
	}

	public function safeDown()
	{
	}
	*/
}