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
- Appwrite (Dart SDK) (for package_info_pl...
Hi team! Many Flutter plugins now need package_info_plus 10.x and device_info_plus 13.x, but appwrite 25.4.0 still constrains package_info_plus: >=8.0.2 <10.0...
- Images/Videos in storage appearing broke...
I am running into a storage issue after upgrading my self-hosted Appwrite instance , all of my previously uploaded images and videos are now showing as broken i...
- executeFunction intermittently throws Fo...
Environment: Flutter app using the Appwrite Flutter SDK, calling executeFunction for [describe endpoint, e.g. live-stream-related function]. *Description*: Int...