Rev 818 | Rev 882 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed
-- date d'observation dans le futurUPDATE `BASEEDIT`.`cel_obs` SET date_observation = NULL WHERE date_observation > now();-- cleanupUPDATE `BASEEDIT`.`cel_obs` SET date_observation = NULL WHERE date_observation = '0000-00-00 00:00:00';-- cleanupUPDATE `BASEEDIT`.`cel_obs` SET latitude = NULL, longitude = NULL WHERE longitude = 0 and latitude = 0;-- referentiels: 65800 NULL, 13000 ''UPDATE `BASEEDIT`.`cel_obs` SET nom_referentiel = SUBSTRING_INDEX(nom_referentiel, ':', 1);UPDATE `BASEEDIT`.`cel_obs` SET nom_referentiel = 'bdtfx' WHERE nom_referentiel IN ('bdtfx_v1','bdnff');-- pas de raison historique mémorisée à une différence '' vs NULLUPDATE `BASEEDIT`.`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-- 3172UPDATE `BASEEDIT`.`cel_obs` c SETc.nom_ret = '',c.nom_sel_nn = NULL,c.nom_ret = NULL,c.nom_ret_nn = NULL,c.nt = NULL,c.famille = NULLWHERE nom_sel = '' OR nom_sel IS NULL;-- problème n°1: mauvais référentiel (bdtfx)UPDATE `BASEEDIT`.`cel_obs` SET nom_referentiel = 'bdtxa' WHERE lieudit = 'Grenade';-- problème n°2: nom_sel NULL, nom_ret NOT NULL: 26 obsUPDATE `BASEEDIT`.`cel_obs` SET nom_sel = nom_ret, nom_sel_nn = nom_ret_nn WHERE nom_sel IS NULL AND nom_ret IS NOT NULL;-- problème n°3: backslashes + newline: 90 + 217 obsUPDATE `BASEEDIT`.`cel_obs` SET commentaire = REPLACE(commentaire, "\n\\\'", "'");UPDATE `BASEEDIT`.`cel_obs` SET commentaire = REPLACE(commentaire, "\\\'", "'");-- problème n°4: ce_zone_geo inutile: 57802 obsUPDATE `BASEEDIT`.`cel_obs` SET ce_zone_geo = NULL WHERE ce_zone_geo = 'INSEE-C:';