summaryrefslogtreecommitdiffstats
path: root/crates/atuin-client/record-migrations/20231127090831_create-store.sql
blob: 53d7886004e2c4111e83b96a53ef6def848cd32f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
-- Add migration script here
create table if not exists store (
  id text primary key,   -- globally unique ID

  idx integer,           -- incrementing integer ID unique per (host, tag)
  host text not null, -- references the host row
  tag text not null,

  timestamp integer not null,
  version text not null,
  data blob not null,
  cek blob not null
);

create unique index record_uniq ON store(host, tag, idx);