Filter through all attributes values at once

I'm using Pandas to write some values in a CSV file, and ingesting this CSV with the Neo4J Python driver.
In order to speed up the project I'm working I setted a default value ("REPLACE_ME_PLEASE") using the Pandas fillna method to populate null values in the CSV.
Now there's only one thing left:
I can have multiple queries to search through each node label and delete this default values, but I'm looking for a query that can ignore node labels and attribute labels, and search only through attribute values.
Is this possible?

Looks a bit cumbersome, as you could have just left those values as null then they wouldn't have been added in the first place.

Depending on the size of your graph this should work:

MATCH (n)
WITH n, [k in keys(n) WHERE n[k] = 'default_value' | k] as keys
call apoc.create.removeProperties(n, keys) yield node
return count(*);
1 Like

Thank you, this works beautifully

1 Like