You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am either doing something wrong or maybe we can add this functionality but I am trying to query objects by UUID. This is definitely possible in healthkit but my best way is to query all items and then filter in typescript which isn't efficient.
createPredicate in react-native-healthkit/ios/Helpers.swift only supports to and from.
I'm not very good w/Swift but happy to submit a PR if there is not a good way to do this.
I mostly need this because I am syncing objects every so often and I want to know before the sync if they already exist or need to be updated since for some reason it's totally possible to write an object twice with the same HKExternalUUID. Right now the only option is to query all healthkit objects within a timeframe.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I am either doing something wrong or maybe we can add this functionality but I am trying to query objects by UUID. This is definitely possible in healthkit but my best way is to query all items and then filter in typescript which isn't efficient.
createPredicate in react-native-healthkit/ios/Helpers.swift only supports to and from.
predicateForObjectsWithUUIDs is supported though
https://developer.apple.com/documentation/healthkit/hkquery/1614785-predicateforobjectswithuuids
I'm not very good w/Swift but happy to submit a PR if there is not a good way to do this.
I mostly need this because I am syncing objects every so often and I want to know before the sync if they already exist or need to be updated since for some reason it's totally possible to write an object twice with the same HKExternalUUID. Right now the only option is to query all healthkit objects within a timeframe.
Beta Was this translation helpful? Give feedback.
All reactions