CREATE TABLE pitching_current (
  eliasID int(6) NOT NULL,
  teamID char(3) DEFAULT NULL,
  gameID varchar(32) NOT NULL,
  gameDate date DEFAULT NULL,
  outs smallint(2) DEFAULT NULL,
  bf smallint(2) DEFAULT NULL,
  hr smallint(2) DEFAULT NULL,
  bb smallint(2) DEFAULT NULL,
  so smallint(2) DEFAULT NULL,
  er smallint(2) DEFAULT NULL,
  runs smallint(2) DEFAULT NULL,
  hits smallint(2) DEFAULT NULL,
  wins smallint(2) DEFAULT NULL,
  losses smallint(2) DEFAULT NULL,
  holds smallint(2) DEFAULT NULL,
  hopps smallint(2) DEFAULT NULL,
  saves smallint(2) DEFAULT NULL,
  sopps smallint(2) DEFAULT NULL,
  cg smallint(2) DEFAULT NULL,
  sho smallint(2) DEFAULT NULL,
  gs smallint(2) DEFAULT NULL,
  PRIMARY KEY (eliasID,gameID)
);

CREATE TABLE rosters_current (
  gameID varchar(32) DEFAULT NULL,
  gameDate date DEFAULT NULL,
  teamID char(3) DEFAULT NULL,
  eliasID int(6) DEFAULT NULL,
  nameFirst varchar(32) DEFAULT NULL,
  nameLast varchar(32) DEFAULT NULL,
  nickName varchar(32) DEFAULT NULL,
  jersey smallint(2) DEFAULT NULL,
  throws char(1) DEFAULT NULL,
  pos char(2) DEFAULT NULL
);

CREATE TABLE fielding_current (
  eliasID int(6) DEFAULT NULL,
  teamID char(3) DEFAULT NULL,
  gameID varchar(32) DEFAULT NULL,
  gameDate date DEFAULT NULL,
  pos char(2) DEFAULT NULL,
  po smallint(2) DEFAULT NULL,
  da smallint(2) DEFAULT NULL,
  e smallint(2) DEFAULT NULL,
  pb smallint(2) DEFAULT NULL
);

CREATE TABLE batting_current (
  eliasID int(6) NOT NULL,
  teamID char(3) DEFAULT NULL,
  gameID varchar(32) NOT NULL,
  gameDate date DEFAULT NULL,
  h smallint(2) DEFAULT NULL,
  hr smallint(2) DEFAULT NULL,
  bb smallint(2) DEFAULT NULL,
  so smallint(2) DEFAULT NULL,
  rbi smallint(2) DEFAULT NULL,
  ab smallint(2) DEFAULT NULL,
  runs smallint(2) DEFAULT NULL,
  t smallint(2) DEFAULT NULL,
  d smallint(2) DEFAULT NULL,
  lob smallint(2) DEFAULT NULL,
  sb smallint(2) DEFAULT NULL,
  cs smallint(2) DEFAULT NULL,
  sf smallint(2) DEFAULT NULL,
  hbp smallint(2) DEFAULT NULL,
  PRIMARY KEY (eliasID,gameID)
);

CREATE TABLE games_current (
  gameID varchar(32) NOT NULL DEFAULT '',
  gameDate date NOT NULL DEFAULT '0000-00-00',
  homeTeam char(3) DEFAULT NULL,
  awayTeam char(3) DEFAULT NULL,
  away_wins smallint(3) DEFAULT NULL,
  away_loss smallint(3) DEFAULT NULL,
  home_wins smallint(3) DEFAULT NULL,
  home_loss smallint(3) DEFAULT NULL,
  status_ind char(3) DEFAULT NULL,
  home_games smallint(3) DEFAULT NULL,
  away_games smallint(3) DEFAULT NULL,
  PRIMARY KEY (gameID,gameDate)
);

