I use Neo4j APOC in order to install the following trigger:
CALL apoc.trigger.add('HAS_VALUE_ON_ADD_TO_INDEX', 'UNWIND {createdRelationships} AS r MATCH (d:Decision)-[r:HAS_VALUE_ON]->(ch:Characteristic) CALL apoc.index.addRelationship(r, keys(r)) RETURN count(*)', {phase:'after'})
Also, I use the following in order to remove the trigger:
CALL apoc.trigger.remove('HAS_VALUE_ON_ADD_TO_INDEX') yield name, installed
I don't want to try to install/remove this trigger when it already exists/doesn't exist.
I'd be really grateful if you can show me the way how I can check the trigger existence with APOC.. probably some Boolean functions (or something like that) that can be used in order to verify it.