begin;
create table if not exists "teamshalfdivisions" (
	"yearID"	numeric,
	"teamID"	text,
	"divID"	text,
	primary key("yearID","teamID")
);

insert into teamshalfdivisions
select distinct yearid, teamid, divid
from teamshalf;

alter table teamshalf drop column "lgID";
alter table teamshalf drop column "divID";
commit;
