DROP TABLE IF EXISTS sacoche_omogen_api;

CREATE TABLE sacoche_omogen_api (
  api_id                  VARCHAR(16) COLLATE utf8_unicode_ci NOT NULL DEFAULT "",
  api_nom                 VARCHAR(60) COLLATE utf8_unicode_ci NOT NULL DEFAULT "",
  api_souscription_statut TINYINT UNSIGNED                             DEFAULT NULL COMMENT "NULL si inexistant, 1 si existant",
  api_activation_etat     TINYINT UNSIGNED                             DEFAULT NULL COMMENT "NULL si inexistant, 1 si activé, 0 si désactivé",
  PRIMARY KEY (api_id)
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

ALTER TABLE sacoche_omogen_api DISABLE KEYS;

INSERT INTO sacoche_omogen_api (api_id, api_nom, api_souscription_statut, api_activation_etat) VALUES
("Siecle-BEE"      , "Siècle base établissement 2nd degré (élèves, parents, ...)", NULL, NULL),
("LSU"             , "LSU compte-rendu des imports"                              , NULL, NULL),
("STSWeb"          , "STS services des personnels 2nd degré"                     , NULL, NULL),
("STSapi"          , "STS personnels établissement 2nd degré"                    , NULL, NULL),
("Omogen-Simplifie", "LSU transfert des données depuis SACoche"                  , NULL, NULL);

ALTER TABLE sacoche_omogen_api ENABLE KEYS;
