As of April 12th, you must go to Progress SupportLink to create new support cases or to access existing cases. Please, bookmark the SupportLink URL and use the new portal to contact the support team.
When I request the record via Kinvey.DataStore.find with no query parameter it returns the thumbnail object with all the data including the _downloadURL, but when I use query to limit the number of fields (e.g. query = query.fields(["_id", "name", "pies", "flows", "thumbnail"]); the thumbnail object I receive does not contain the _downloadURL any more, it only contains
{_type: "KinveyFile", _id: "thumb-jhtk3ccoi"}.
Why? How do I get limited fields from my collection while also receiving the _downloadURL of my thumbnail?
Best Answer
D
Damien Bell
said
over 8 years ago
Good morning again Daniel,
Our wonderful JS developer Thomas has whipped up a query that should solve the issues that you are running into:
daniel_sedlacek
I have a collection where every record has an image (thumbnail). Name of the filed is "thumbnail" and it contains this:
{
"_id": "thumb-n9ojr7aa8",
"size": 7099,
"mimeType": "image/jpeg",
"_filename": "34d1ebd4-4728-455e-8807-190a00798695",
"_acl": {
"creator": "54aeae56c0f223865101f894"
},
"_kmd": {
"lmt": "2015-04-17T10:07:44.009Z",
"ect": "2015-04-16T15:28:33.802Z"
},
"_downloadURL": "http://storage.googleapis.com/kinvey_production_da839956b9c54d749b196e68a2fb7d5b/thumb-n9ojr7aa8/34d1ebd4-4728-455e-8807-190a00798695?GoogleAccessId=558440376631@developer.gserviceaccount.com&Expires=1429270998&Signature=NItWQ4qmthOXjXNpEP73%2BHTxFAUegSzKOQlbO%2F4mIi0hMuJhiJ2AttAZFvM1bqeLGPXwhiil3VgqzZ5amZ%2Bt9LQ%2FJfaDTrh4uD1WKVqMhVmiG3o0AfIoLiOGdsB5RUAKyiFcxfItDDO3Fd8f32pYbCDTFsqG2%2BdTSCTIpuH7wZo%3D",
"_expiresAt": "2015-04-17T11:43:18.250Z",
"_type": "KinveyFile"
}
When I request the record via Kinvey.DataStore.find with no query parameter it returns the thumbnail object with all the data including the _downloadURL, but when I use query to limit the number of fields (e.g. query = query.fields(["_id", "name", "pies", "flows", "thumbnail"]); the thumbnail object I receive does not contain the _downloadURL any more, it only contains
{_type: "KinveyFile", _id: "thumb-jhtk3ccoi"}.
Why? How do I get limited fields from my collection while also receiving the _downloadURL of my thumbnail?
Good morning again Daniel,
Our wonderful JS developer Thomas has whipped up a query that should solve the issues that you are running into:
We think that this should grab what you need. The relations bit is what is grabbing the downloadURL for you
Please let me know if you have any other questions,
- Oldest First
- Popular
- Newest First
Sorted by Newest Firstdaniel_sedlacek
nice workaround, thanks
Damien Bell
Good morning again Daniel,
Our wonderful JS developer Thomas has whipped up a query that should solve the issues that you are running into:
We think that this should grab what you need. The relations bit is what is grabbing the downloadURL for you
Please let me know if you have any other questions,
-
How do I use Kinvey in my web app?
-
Is it safe to include keys/secrets in my client-side JavaScript app?
-
Why is the activeUser null even though I am logged in?
-
Login does not work even though credentials are valid.
-
Social login doesn’t work.
-
Appending objects to an Array (HTML5 - JS)
-
New to node.js - need bootstrap to downloadfiles from Kinvey
-
Problem with Aggregation/Grouping
-
Internal Server Error using Twitter Sign Up
-
Data Store
See all 315 topics