Thanks, i have corrected the error however the relationship is not created.
//link bus stop to another bus stop give the properties as time and distance
router.post('/busstop/busstop/add', function (req, res) {
var bus_stopname = req.body.busstop_name;
var bus_stopname = req.body.busstop_name;
var cost = req.body.cost;

session
.run('MATCH(a:Bstop {bus_stopname:{bus_stopnameParam}}), (b:Bstop 
{bus_stopname:{bus_stopnameParam}}) MERGE(b)-[r:FEES 
{cost:{costParam}}]-(a) RETURN a,b ', { costParam:cost,bus_stopnameParam: 
bus_stopname, bus_stopnameParam: bus_stopname })
.then(function (result) {
res.redirect('/')
session.close()
})

.catch(function (err) {
console.log(err)
});
})

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to neo4j+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to