Blame view
api/database/migrations/2021_07_26_070122_create_od_mltd_relations.php
1.21 KB
ed6f1e55d Added migration f... |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
<?php use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Schema; class CreateOdMltdRelations extends Migration { /** * Run the migrations. * * @return void */ public function up() { DB::statement('CREATE TABLE IF NOT EXISTS od(' . 'uuid serial PRIMARY KEY,' . 'asset_id VARCHAR (100) NOT NULL,' . 'value REAL NOT NULL,' . 'incident_date TIMESTAMP NOT NULL,' . 'timeframe VARCHAR (355) NOT NULL,' . 'created_on TIMESTAMP NOT NULL)'); |
aad89f8f9 Replacing od with... |
24 |
DB::statement('CREATE TABLE IF NOT EXISTS mltd(' . |
ed6f1e55d Added migration f... |
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
'uuid serial PRIMARY KEY,' . 'asset_id VARCHAR (100) NOT NULL,' . 'probability REAL NOT NULL,' . 'timeframe VARCHAR (355) NOT NULL,' . 'created_on TIMESTAMP NOT NULL)'); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('od'); Schema::dropIfExists('mltd'); } } |