fix: link old
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('analytics_daily_dims', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('stat_date', 10);
|
||||
$table->string('scope_key', 32)->default('');
|
||||
$table->string('kind', 32);
|
||||
$table->string('dim', 64)->default('');
|
||||
$table->unsignedInteger('uv')->default(0);
|
||||
$table->unsignedInteger('effective_uv')->default(0);
|
||||
$table->unsignedInteger('devices')->default(0);
|
||||
$table->unsignedBigInteger('seconds_sum')->default(0);
|
||||
$table->timestamp('computed_at')->nullable();
|
||||
$table->unique(['stat_date', 'scope_key', 'kind', 'dim'], 'analytics_daily_dims_uniq');
|
||||
$table->index(['scope_key', 'stat_date', 'kind'], 'analytics_daily_dims_lookup');
|
||||
});
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('analytics_daily_dims');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user