lahmanlite/sql/keys/awardssharemanagers.sql

17 lines
446 B
MySQL
Raw Normal View History

2024-01-26 00:48:11 +00:00
begin;
CREATE TABLE IF NOT EXISTS "pk_awardssharemanagers" (
"awardID" TEXT,
"yearID" NUMERIC,
"lgID" TEXT,
"playerID" TEXT,
"pointsWon" NUMERIC,
"pointsMax" NUMERIC,
"votesFirst" NUMERIC,
PRIMARY KEY("playerID","awardID","yearID","lgID")
);
INSERT INTO "pk_awardssharemanagers" SELECT DISTINCT * FROM "awardssharemanagers";
DROP TABLE "awardssharemanagers";
ALTER TABLE "pk_awardssharemanagers" RENAME TO "awardssharemanagers";
commit;