package Common::DB::Schema::Report::SysDbReplicaDiff;

use strict;
use warnings;

use lib '/app/tools/common/lib';
use base 'Common::DB::DBIxCore';

## table
__PACKAGE__->table('report.sys_db_replica_diff');

## columns
__PACKAGE__->add_columns(qw/
    sys_db_replica_diff_id
    primary_host
    replica_host
    dbname
    tabname
    keycol
    minrow
    maxrow
    primary_cnt
    replica_cnt
    is_diff
    message
    diff_json
/);

## primary key
__PACKAGE__->set_primary_key('sys_db_replica_diff_id');

## unique key (primary_host, replica_host, dbname, tabname, minrow)
__PACKAGE__->add_unique_constraint('uidx_host_db_tab_row' => [qw/primary_host replica_host dbname tabname minrow/]);

1;
