Open
Description
It is almost impossible to wait for 15,000 rows with the SDO_GEOMETRY data type.
fetchArraySize does not affect the process of fetching object data.
However, using the same code to fetch regular data types is fast.
connection = await oracledb.getConnection(dbConfig);
oracledb.fetchArraySize = 1000;
let t0 = performance.now()
result = await connection.execute(
`select geometry from g where rownum < 15000`,
[],
{
outFormat: oracledb.OUT_FORMAT_OBJECT
}
);
console.log(result.rows.length);
let count = 0
let all = ""
for (const row of result.rows) {
all += JSON.stringify(row.geometry)
count++
}
let t1 = performance.now()
console.log(" Fetch" + (t1 - t0) + " milliseconds.")
output:
14999
Fetch 604606.555001 milliseconds.
> process.platform
'win32'
> process.version
'v12.6.0'
> process.arch
'x64'
> require('oracledb').versionString
'4.0.0'
>
Oracle Database version = 11.2.0.3