<?php
$_db_migration_to = '26.21'; // 8.0.16
if (!isset($migrations) || !is_object($migrations))
	die("This file cannot be executed directly");
$migrations->CheckValid($_db_migration_to);
//===========================================================================================



$migrations->Run('01_cdn_files_idx_lookup.php', <<<'DB_UPDATE_FILE'
<?php
/** @var \Claromentis\Setup\SetupFacade $migrations */

// CREATE INDEX idx_url_lookup ON cdn_files (type, parent_path(50),name(50));
$database = $migrations->GetDb();
$database->CreateIndex('cdn_files', 'cdn_files_url_lookup', 'type', 'parent_path(50)', 'name(50)');

DB_UPDATE_FILE
);


//===========================================================================================
$migrations->SetVersion('26.21');
