Subversion Repositories eFlore/Projets.eflore-projets

Rev

Rev 755 | Rev 760 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

-- date d'observation dans le futur
UPDATE cel_obs SET date_observation = NULL WHERE date_observation > now();
-- cleanup
UPDATE cel_obs SET date_observation = NULL WHERE date_observation = '0000-00-00 00:00:00';
-- cleanup
UPDATE cel_obs SET latitude = NULL, longitude = NULL WHERE longitude = 0 and latitude = 0;

-- referentiels: 65800 NULL, 13000 ''
UPDATE cel_obs SET nom_referentiel = SUBSTRING_INDEX(nom_referentiel, ':', 1);
UPDATE cel_obs SET nom_referentiel = 'bdtfx' WHERE nom_referentiel IN ('bdtfx_v1','bdnff');
-- TODO: UPDATE cel_obs SET nom_referentiel = NULL where nom_referentiel = '';

-- suppression des infos générées pour les observations dont le nom_sel à été supprimé par l'utilisateur
-- 3172
UPDATE tb_cel.cel_obs c SET
       c.nom_ret = '',
       c.nom_sel_nn = NULL,
       c.nom_ret = NULL,
       c.nom_ret_nn = NULL,
       c.nt = NULL,
       c.famille = NULL;
       WHERE nom_sel = '' OR nom_sel IS NULL;