Fix various issues in legacy db import

Most important: Remove `#` symbol from Tags and snakeCase them.
This commit is contained in:
roschaefer 2019-08-15 23:04:14 +02:00
parent 1c1d74e30d
commit bb4b3196a7
3 changed files with 3 additions and 4 deletions

View File

@ -38,14 +38,12 @@ export_collection "emotions"
export_collection_query "follows" "{'foreignService': 'organizations'}" "organizations" export_collection_query "follows" "{'foreignService': 'organizations'}" "organizations"
export_collection_query "follows" "{'foreignService': 'users'}" "users" export_collection_query "follows" "{'foreignService': 'users'}" "users"
export_collection "invites" export_collection "invites"
export_collection "notifications"
export_collection "organizations" export_collection "organizations"
export_collection "pages" export_collection "pages"
export_collection "projects" export_collection "projects"
export_collection "settings" export_collection "settings"
export_collection "shouts" export_collection "shouts"
export_collection "status" export_collection "status"
export_collection "systemnotifications"
export_collection "users" export_collection "users"
export_collection "userscandos" export_collection "userscandos"
export_collection "usersettings" export_collection "usersettings"

View File

@ -148,6 +148,6 @@ MATCH (c:Category {id: categoryId})
MERGE (p)-[:CATEGORIZED]->(c) MERGE (p)-[:CATEGORIZED]->(c)
WITH p, post.tags AS tags WITH p, post.tags AS tags
UNWIND tags AS tag UNWIND tags AS tag
MERGE (t:Tag {id: tag, name: tag}) MERGE (t:Tag {id: apoc.text.clean(tag), disabled: false, deleted: false})
MERGE (p)-[:TAGGED]->(t) MERGE (p)-[:TAGGED]->(t)
; ;

View File

@ -1 +1,2 @@
MATCH (n:User) DETACH DELETE n; MATCH (n:User) DETACH DELETE n;
MATCH (e:EmailAddress) DETACH DELETE e;