millions/db/schema.sql

35 lines
844 B
MySQL
Raw Permalink Normal View History

2020-01-15 13:24:55 +00:00
-- Adminer 4.7.5 SQLite 3 dump
CREATE TABLE "sites" (
2020-01-16 11:49:22 +00:00
"id" integer NOT NULL PRIMARY KEY AUTOINCREMENT,
2020-01-15 13:24:55 +00:00
"host" text COLLATE 'NOCASE' NOT NULL,
"label" text NULL,
"stats_public" numeric NOT NULL DEFAULT '0',
2020-01-15 14:48:45 +00:00
"stats_key" text NULL
2020-01-15 13:24:55 +00:00
);
CREATE UNIQUE INDEX "sites_host" ON "sites" ("host");
CREATE TABLE "visits" (
"site_id" integer NOT NULL,
"path" text NOT NULL,
"ts" numeric NOT NULL,
2020-01-15 14:48:45 +00:00
"is_unique" numeric NOT NULL DEFAULT '0',
"is_bot" numeric NOT NULL DEFAULT '0',
"platform" text NOT NULL DEFAULT '',
2020-01-15 13:24:55 +00:00
"browser" text NOT NULL DEFAULT '',
2020-01-15 14:48:45 +00:00
"version" text NOT NULL DEFAULT '',
2020-01-15 13:24:55 +00:00
"ref" text NOT NULL DEFAULT '',
"width" integer NOT NULL DEFAULT ''
);
CREATE INDEX "visits_site_id_path" ON "visits" ("site_id", "path");
2020-02-04 11:05:41 +00:00
CREATE TABLE "uas" (
"ua" text NOT NULL
);
CREATE UNIQUE INDEX "uas_ua" ON "uas" ("ua");
2020-01-15 13:24:55 +00:00
--