export const getPatient = async (userId: string) => { try { const patients = await databases.listDocuments( DATABASE_ID!, PATIENT_COLLECTION_ID!, [Query.equal('userId', [userId])] )
return parseStringify(patients.documents[0])
} catch (error) { console.log(error) } }
im getting null here, not sure what am i doing wrong. I created relationship between patiens collection and appointment and its a one way
Recommended threads
- delete document problems
i don't know what's going on but i get an attribute "tournamentid" not found in the collection when i try to delet the document... but this is just the document...
- Update User Error
```ts const { users, databases } = await createAdminClient(); const session = await getLoggedInUser(); const user = await users.get(session.$id); if (!use...
- apple exchange code to token
hello guys, im new here 🙂 I have created a project and enabled apple oauth, filled all data (client id, key id, p8 file itself etc). I generate oauth code form...