DNG > RPE - Sort Artifacts by Custom Attribute
Is there a clever way I can sort artifacts in a datasource by a custom attribute for publishing?
i.e. is there a way, using javascript, I can capture all the data I want to publish upfront in some sort of an array then sort it, save it to an RPE variable and then iterate through them for publishing? What limitations am I likely to face if I'm publishing many (>1000) artifacts?
|
3 answers
Theoretically there is no limitation. You can also think of storing only the artifact URLs (sorted on their custom attribute value) in an array and for each element in that array do a data request (data source configuration within an Iteration element). If you are concerned about document generation time, reporting on Views would be better. |
Hi Glyn,
If You use a DNG view as a data source then you can sort the data in the view. This way you will get sorted data in XML that you get through reportable API.
|
Looks like there is actually a detailed description of how this can be achieved here: https://softacus.com/blog/articles/epe/publishing-engine-array-memory
thank you for your responses.
Comments Glyn,
To get those information you need to use the view with this attribute or get attribute for every object. You can later add those elements to array according to the provided article and sort it using array sort function.
Be aware that if You are already using the view it is more efficient to do it in the view than in the report if You have large number of artifacts.
Both methods will work but concert is report generation time when having larger workload of data.
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.