| package sql |
| |
| // Generated by //go/sql/exporter/ |
| // DO NOT EDIT |
| |
| const Schema = `CREATE TABLE IF NOT EXISTS Alerts ( |
| id INT PRIMARY KEY DEFAULT unique_rowid(), |
| alert TEXT, |
| config_state INT DEFAULT 0, |
| last_modified INT |
| ); |
| CREATE TABLE IF NOT EXISTS Commits ( |
| commit_number INT PRIMARY KEY, |
| git_hash TEXT UNIQUE NOT NULL, |
| commit_time INT, |
| author TEXT, |
| subject TEXT |
| ); |
| CREATE TABLE IF NOT EXISTS ParamSets ( |
| tile_number INT, |
| param_key STRING, |
| param_value STRING, |
| PRIMARY KEY (tile_number, param_key, param_value), |
| INDEX by_tile_number (tile_number DESC) |
| ); |
| CREATE TABLE IF NOT EXISTS Postings ( |
| tile_number INT, |
| key_value STRING NOT NULL, |
| trace_id BYTES, |
| PRIMARY KEY (tile_number, key_value, trace_id), |
| INDEX by_trace_id (tile_number, trace_id, key_value) |
| ); |
| CREATE TABLE IF NOT EXISTS Regressions ( |
| commit_number INT, |
| alert_id INT, |
| regression TEXT, |
| PRIMARY KEY (commit_number, alert_id) |
| ); |
| CREATE TABLE IF NOT EXISTS Shortcuts ( |
| id TEXT UNIQUE NOT NULL PRIMARY KEY, |
| trace_ids TEXT |
| ); |
| CREATE TABLE IF NOT EXISTS SourceFiles ( |
| source_file_id INT PRIMARY KEY DEFAULT unique_rowid(), |
| source_file STRING UNIQUE NOT NULL, |
| INDEX by_source_file (source_file, source_file_id) |
| ); |
| CREATE TABLE IF NOT EXISTS TraceValues ( |
| trace_id BYTES, |
| commit_number INT, |
| val REAL, |
| source_file_id INT, |
| PRIMARY KEY (trace_id, commit_number), |
| INDEX by_source_file_id (source_file_id, trace_id) |
| ); |
| ` |
| |
| var Alerts = []string{ |
| "id", |
| "alert", |
| "config_state", |
| "last_modified", |
| } |
| |
| var Commits = []string{ |
| "commit_number", |
| "git_hash", |
| "commit_time", |
| "author", |
| "subject", |
| } |
| |
| var ParamSets = []string{ |
| "tile_number", |
| "param_key", |
| "param_value", |
| } |
| |
| var Postings = []string{ |
| "tile_number", |
| "key_value", |
| "trace_id", |
| } |
| |
| var Regressions = []string{ |
| "commit_number", |
| "alert_id", |
| "regression", |
| } |
| |
| var Shortcuts = []string{ |
| "id", |
| "trace_ids", |
| } |
| |
| var SourceFiles = []string{ |
| "source_file_id", |
| "source_file", |
| } |
| |
| var TraceValues = []string{ |
| "trace_id", |
| "commit_number", |
| "val", |
| "source_file_id", |
| } |