oracle / node-oracledb

Oracle Database driver for Node.js maintained by Oracle Corp.
http://oracle.github.io/node-oracledb/
Other
2.25k stars 1.07k forks source link

ErrorNum: 0 what does it mean? #1500

Closed Mohammed-Ahmed-Ismail closed 2 years ago

Mohammed-Ahmed-Ismail commented 2 years ago

I'm having this error {"errorNum":0,"offset":0} while performing an Update, it happen most times not at all , someone knows the meaning of this return ? Is it related to high amounts of requests ? If i need to change change some attribute when creating pool to solve that ?

kindly find the below code that catch the mention error

async function execute() {
    let connection = await connectionPool.getConnection();
    try {
        oracledb.fetchAsString = [ oracledb.CLOB ];
        let result = await connection.execute(...arguments);
        return result;
    } catch (error) {
        logger.error({ Error: error, Data: arguments });
        return -1;
    } finally {
        await connection.close();
    }
}

using "oracledb": 4.1.0

cjbj commented 2 years ago

[I formatted your code: use triple back ticks on their own line for code blocks]

Without an actual test case I can't guess what's going on. No one else has reported it. What version of Oracle DB and Oracle client libraries do you have? You code raises a couple of questions:

sosoba commented 2 years ago

Maybe you are trying to retrieve CLOB content from the result ouside this function while the connection is already closed by your wrapper.

stale[bot] commented 2 years ago

This issue has been automatically marked as inactive because it has not been updated recently. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] commented 2 years ago

This issue has been automatically closed because it has not been updated for a month.