If I try to get records greater than 1,000, I get the "expecting POST /_api/cursor" error when I call the cursor.all() method in ArangoDB.js.
Here is my installation: ArangoDB version 3.7.6 ArangoDB.js versioin 8.6.0 Node.js version 18.14.0
To replicate:
const Database = require( 'arangojs' ).Database;
let db = new Database({
url: 'HTTP://127.0.0.1:8529',
databaseName: 'TEST',
auth: { username: 'root', password: 'test' }
});
let cursor = await db.query( 'FOR doc1 IN FOICU RETURN { "CU_NAME": doc1.CU_NAME }' );
let result = await cursor.all();
return result;
If I add 'LIMIT 100' to the query, everything works as expected. If I add 'LIMIT 1001' or anything over 1,000 I get the error.
I want to implement paging but the cursor fails when I even call the cursor.fullCount(). Any ideas what I can try?
My TEST database, collection: FOICU has 100,000 records with only one attribute called CU_NAME I can use the web interface and get all the records so I can dump to a file, but I can't get all the records using the ArangoDB.js driver.
Any ideas?