Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
03-12-2020 04:06 AM
Dear sir or madam,
The following issue is ocurring when for example renaming by the apoc procedure CALL apoc.refactor.rename.label('old','new');
The old labels still exists eventhough there is node of this label any longer.
I actually do have the same issue with no longer existant properties which when queried don't result in any nodes (entities) or relationships.
Is there any way to force a refactoring solving this issue?
Thank you very much in advance.
Kindest Regards,
Malte Roessner
03-12-2020 04:23 AM
Hello together,
after applying the above mentioned APOC Procudure the renewal seems to not taking place right away.
I can't access the renamed data, how can I force a rebuild of the strcuture.
Thank you and kindest Regards,
Malte
03-12-2020 05:00 AM
Hi @MalteR,
I tried
call apoc.refactor.rename.label('BTC','BTC1')
And now when I tried match(n:BTC) return n it did not give any node
And Match(n:BTC1) gave me renamed nodes
03-12-2020 05:09 AM
Hi Vivek,
actually might be with regards to the amount of data, what I do is the follwing:
renaming to an existant node label, when querying the old lable it's still existing but when querying the new one with where clause to the new and old source I do get the following:
MATCH (n:ENTITY) RETURN distinct n.source LIMIT 25 * Table
Text
Code
n.source
"RISE NETWORK"
"COMBINED LAUNDROMAT RU RO"
"KROLL REPORT"
"PARADISE PAPERS"
"PANAMA PAPERS"
"OFFSHORE LEAKS"
"BAHAMAS LEAKS"
"COMPANIES HOUSE"
The switched source with regards to node type ENTITY is "COMPANIES HOUSE"
but if I then do the following query I do not get any result as follows:
MATCH (n:ENTITY) where n.source = "COMPANIES HOUSE" RETURN n LIMIT 25
Table
Code
(no changes, no records)
And as written I do have as well no longer existing Property Keys for a couple of weeks.
Thank you very much in advance.
MATCH (n) RETURN count(n) * Table
Text
Code
count(n)
56634979
I tried restarting the server already.
Kindest Regards,
Malte R.
03-12-2020 10:35 AM
03-12-2020 10:45 AM
Hi Vivek,
time seems to have cleaned up something in my database.
match (n:ENTITY) where n.source = 'COMPANIES HOUSE' return n.name limit 5; * Table
Text
Code
n.name
"LTD"
"LTD"
"BIG IMPACT GRAPHICS LTD"
"NNOV8 LTD"
"NSPIRED INVESTMENTS LTD"
But I do still have data which shouldn't be there any longer as it is the old LABEL, that when get queried brings up no data, see as folows:
Perhaps anyone can help out.
Best,
Malte
03-12-2020 10:45 AM
CALL apoc.refactor.rename.label('LEGALENTITY','ENTITY');
This was the actual call.
Kindest Regards,
Malte
03-12-2020 10:47 AM
My question is so how to force a removal of deleted LABELS and PROPERTIES from the list of the browser based query window.
03-12-2020 12:01 PM
MATCH (n) WHERE EXISTS(n.origion_country)
RETURN DISTINCT "node" as entity, n.origion_country AS origion_country LIMIT 25
UNION ALL MATCH ()-[r]-() WHERE EXISTS(r.origion_country)
RETURN DISTINCT "relationship" AS entity, r.origion_country AS origion_country LIMIT 25;
MATCH (n) WHERE EXISTS(n.brand)
RETURN DISTINCT "node" as entity, n.brand AS brand LIMIT 25
UNION ALL MATCH ()-[r]-() WHERE EXISTS(r.brand)
RETURN DISTINCT "relationship" AS entity, r.brand AS brand LIMIT 25;
MATCH (n:LEGALENTITY)
RETURN n LIMIT 25;
These are the queries for screenshots above.
03-19-2020 05:22 AM
Dear all helpers:
I have solved the issue with the labels by dropping all the still existing indexes.
The problem that still remains is the property, but in the end I guess I have to live with it or redo the database.
Thank you all.
03-19-2020 08:56 AM
Dear @MalteR,
Sorry I did not get chance to look into your issue..
Good to hear that you resolved most ..
Please let me know what exactly is left to solve.
All the sessions of the conference are now available online