BulkWrite only works from cloudfunctions.
This is going to take awhile.
BulkWrite only works from cloudfunctions.
This is going to take awhile.
can you test first if it works fine with few rows?
It fails with 20 rows. All objectIds appear to be unique
This works. It appears to be an issue with direct database access. When i manually upload each row individually, then the cloud function works just fine.
Hi Daniel,
I write this code on Job Clound and I got same issue like you, I just have 1 row :).
const query_trans = new Moralis.Query('Transactions');
query_trans.equalTo('hash','0xa56f');
const results = await query_trans.first({useMasterKey: true});
logger.info(JSON.stringify(results)); <---- Print correct
results.set('status', 1);
await results_trans.save(null, {useMasterKey: true})
But got error Object Not Found
I donβt know why ??
Did you do any changes to the database by connecting directly to mongo db?
yes bro, I m insert data directly to mongo db with my api
But on Moralis dashboard donβt show field
I still can find() but canβt update fields
You have to insert a string for id instead of an object
My syntax api:
You have to force somehow for the id to be string
Where now is ObjectId
Mongo insertOne function auto generate ObjectId from my data
You can overwrite it somehow, others managed to set a string in the past
OK thanks bro, I got it. I will generate ID by myself. Thanks for your support
I change Id to string but fields not show in dashboard Moralis, just show in MongoDB Compass.
But now update is OK
Resolved
You have to add the columns in dashboard interface in order to see them
Thanks CryptoKid for good supports