commandLineCall Not Signed In error
Posted: Thu Dec 12, 2019 10:21 am
Hello everybody,
I have a Profound.js instance installed on an IBMi server. Inside its node_modules, I have an application. What I'm trying to do, is to create a shell script that asks some informations to the user and then connects to an IBMi server and querys its database.
To do so, I am trying to take advantage of the features of Profound.js.
Cleaning the code to the basic operations, what I am doing is this:
Node.js code
Profound.js module (located inside the modules directory of my Profound.js instance)
What I get as a result is the following exception:
My Profound.js instance is active as a batch process on the IBMi server.
Thank you in advance.
Best regards.
Adriano
I have a Profound.js instance installed on an IBMi server. Inside its node_modules, I have an application. What I'm trying to do, is to create a shell script that asks some informations to the user and then connects to an IBMi server and querys its database.
To do so, I am trying to take advantage of the features of Profound.js.
Cleaning the code to the basic operations, what I am doing is this:
Node.js code
Code: Select all
// Load Profound.js
var profoundjs = require('profoundjs');
const param = 'test';
// Call module
profoundjs.commandLineCall('iframework/pjsFunctions/test_i18n', param);
Code: Select all
function testQuery () {
const translations = pjs.query('select * from profoundui.puitransp');
}
module.exports.run = testQuery;
Code: Select all
/pjs-instances/iframework/node_modules/profoundjs/api/fiber.jse:134
throw error;
^
Profound.js Error: Not signed in.
See https://docs.profoundlogic.com/docs/display/PUI/Not+signed+in
at Object.profound.utils.connectorMessage (/pjs-instances/iframework/node_modules/profoundjs/utils/connectorMessage.jse:129:11)
at Object.profound.callProcedure (/pjs-instances/iframework/node_modules/profoundjs/api/callProcedure.jse:78:30)
at Object.db.connect (/pjs-instances/iframework/node_modules/profoundjs/db/drivers/IBMi/sql-driver.jse:185:40)
at Object.profound.connect (/pjs-instances/iframework/node_modules/profoundjs/api/connect.jse:5:15)
at Object.profound.utils.getConnection (/pjs-instances/iframework/node_modules/profoundjs/utils/getConnection.jse:23:16)
at Object.profound.prepare (/pjs-instances/iframework/node_modules/profoundjs/db/sql-driver.jse:789:30)
at Object.db.query (/pjs-instances/iframework/node_modules/profoundjs/db/drivers/IBMi/sql-driver.jse:105:23)
at Object.profound.query (/pjs-instances/iframework/node_modules/profoundjs/api/query.jse:4:13)
at Object.pjs.(anonymous function) [as query] (/pjs-instances/iframework/node_modules/profoundjs/api/pjs.jse:21:30)
at Object.testQuery (/pjs-instances/iframework/modules/iframework/pjsFunctions/test_i18n.js:3:28)
Thank you in advance.
Best regards.
Adriano