Browse Source

Force désir de chirurgie as character in both sources

master
Maxime Wack 3 years ago
parent
commit
e4c279db80
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      feed_db.R

+ 2
- 0
feed_db.R View File

@@ -36,6 +36,7 @@ db %>%
select(Etat, Etudiant, `Vœu`, Rang, Subdivision, Discipline, `Désir (non officiel) en chirurgie générale`, timestamp) %>%
collect(n = Inf) %>%
group_by(Etudiant) %>%
mutate_at(vars(`Désir (non officiel) en chirurgie générale`), as.character) %>%
filter(timestamp == max(timestamp)) ->
current

@@ -87,6 +88,7 @@ listing

# Ajout des différences avec timestamp
listing %>%
mutate(`Désir (non officiel) en chirurgie générale` = `Désir (non officiel) en chirurgie générale` %>% as.character) %>%
anti_join(current, by = c("Etat", "Etudiant", "Vœu", "Rang", "Subdivision", "Discipline", "Désir (non officiel) en chirurgie générale")) %>%
dbWriteTable(conn = db, value = ., name = "trajectoires", append = T)



Loading…
Cancel
Save