What does this error means ??
final businessDatabyIDResponse = await _db.listDocuments( databaseId: AppwriteConstants.databaseID, collectionId: AppwriteConstants.businessInfoCollections, queries: [Query.equal('business_owner_id', myBusinessDetailsId)], );
my code
Its resolved now i need to write myBusinessDetailsId like [myBusinessDetailsId]
Not working
what is not working ?
final businessDatabyIDResponse = await _db.listDocuments( databaseId: AppwriteConstants.databaseID, collectionId: AppwriteConstants.businessInfoCollections, queries: [Query.equal('business_owner_id', myBusinessDetailsId)], );
This code
Alright make sure you have setup the permissions correctly for the collection in appwrite console
im trying to fetch data where business_owner_id = 'someownerid from auth users'
Is it correct ?
Yes this means users have the access
can you pls send the error message
Its in the subject 400 generak_argument_invalid, index not found:business_owner_id
You are using appwrite cloud right ?
yes
ok so i think you need to create an index go to the index tab and create an index for business_owner_id field
why ?
In order to do queries you need to create index
You can learn more about them here https://appwrite.io/docs/databases#indexes
Recommended threads
- login With OAuth Failed
login With OAuth Failed: when i cliick to login with any of the following (facebook, gmail or apple) am being redirected out of the app to enter my detail, afte...
- Flutter OAuth2 webAuth Bug?
I created with flutter an app where I can login in with my Microsoft Account. When I compile it to Web (WASM) or Android (aab) then there is no problem what so ...
- Synchronous Function Execution Timed Out...
Hi Appwrite team 👋 I’m facing a synchronous function execution timeout issue on Appwrite Cloud and would appreciate some guidance. I executed this function u...