Error on receiving Json Data

Im trying to do a simple application with neo4j and nodejs, but I've just get stuck in this strange response. I'm inserting things on neo4j and it works, but when I try to use cypher to catch other node attributes i find this mistake:

 Result {
      _stack: '\n    at captureStacktrace (/home/jake/node_modules/neo4j-driver/lib/v1/result.js:199:15)\n    at new Result (/home/jake/node_modules/neo4j-driver/lib/v1/result.js:65:19)\n    at Session._run (/home/jake/node_modules/neo4j-driver/lib/v1/session.js:152:14)\n    at (/home/jake/node_modules/neo4j-driver/lib/v1/session.js:130:19)\n    at /home/jake/Área de Trabalho/simples/index.js:16:31\n    at Layer.handle [as handle_request] (/home/jake/node_modules/express/lib/router/layer.js:95:5)\n    at next (/home/jake/node_modules/express/lib/router/route.js:137:13)\n    at Route.dispatch (/home/jake/node_modules/express/lib/router/route.js:112:3)\n    at Layer.handle [as handle_request] (/home/jake/node_modules/express/lib/router/layer.js:95:5)\n    at /home/jake/node_modules/express/lib/router/index.js:281:22',
   SessionStreamObserver {
     _fieldKeys: null,
     _fieldLookup: null,
     _queuedRecords: [],
     _tail: null,
     _error: null,
     _hasFailed: false,
     _observer: null,
     _conn: null,
     _meta: {},
      Session {
        _mode: 'WRITE',
        _readConnectionHolder: [Object],
        _writeConnectionHolder: [Object],
        _open: true,
        _hasTx: false,
        _lastBookmark: [Object],
        _transactionExecutor: [Object] } },
  _p: null,
  _statement: 'MATCH (p:Person) WHERE =\'$name\' return p.age',
  _parameters: { name: 'Jake' },
  _metaSupplier: [Function],
   ConnectionHolder {
     _mode: 'WRITE',
      DirectConnectionProvider {
        _address: [Object],
        _connectionPool: [Object],
        _driverOnErrorCallback: [Function: bound _driverOnErrorCallback] },
     _referenceCount: 1,
     _connectionPromise: Promise { <pending> } } }'

To make it clear: i just want to find a node by its name and then show its age. I was expecting a Json data.

My code:

`const express = require ("express");
const app = express();
const bodyParser = require('body-parser');


const neo4j = require('neo4j-driver').v1;
const driver = neo4j.driver('bolt://localhost:7687', neo4j.auth.basic('neo4j', '123'));
const session = driver.session();

// Data Manipulation'/', function (req, res){
var find = req.body.pesquisa;
  const result_dois ="MATCH (p:Person) WHERE ='$name' return p.age", {name:find});




If someone could help...

Never used the javascript driver myself but I am giving it a shot :slight_smile:

Perhaps the should be awaited for?

Its what I notice looking at the example of the driver:

const neo4j = require('neo4j-driver')

const driver = neo4j.driver(uri, neo4j.auth.basic(user, password))
const session = driver.session()
const personName = 'Alice'

try {
  const result = await
    'CREATE (a:Person {name: $name}) RETURN a',
    { name: personName }

  const singleRecord = result.records[0]
  const node = singleRecord.get(0)

} finally {
  await session.close()

// on application exit:
await driver.close()