forked from ddrilling/AsbCloudServer
add migration hypertable and chunks
This commit is contained in:
parent
a53bf11900
commit
b922ac245a
7943
AsbCloudDb/Migrations/20230327212807_WITS_GTR_manual_hypertable.Designer.cs
generated
Normal file
7943
AsbCloudDb/Migrations/20230327212807_WITS_GTR_manual_hypertable.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,23 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace AsbCloudDb.Migrations
|
||||
{
|
||||
public partial class WITS_GTR_manual_hypertable : Migration
|
||||
{
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.Sql
|
||||
("SELECT create_hypertable('t_wits_base','time','id_telemetry',chunk_time_interval => INTERVAL '5 day'); " +
|
||||
"SELECT create_hypertable('t_wits_string','time','id_telemetry',chunk_time_interval => INTERVAL '5 day'); " +
|
||||
"SELECT create_hypertable('t_wits_float','time','id_telemetry',chunk_time_interval => INTERVAL '5 day'); " +
|
||||
"SELECT create_hypertable('t_wits_int','time','id_telemetry',chunk_time_interval => INTERVAL '5 day'); ");
|
||||
}
|
||||
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user