It's all about the answers!

Ask a question

When using the REST API is there a modifier for an item such as first and last?

Shaule Sachs (18136) | asked Aug 15 '16, 11:53 a.m.
 When using the report repository, I can do...|archived|itemHistory/*)

which gives me all the itemHistory elements, but in truth, I just want the first and last itemHistory.

In XPath (and such) you can do:|archived|itemHistory[first()]/*|itemHistory[last()]/*)
but that gives me a 500 error.

Anyone have any ideas?

One answer

permanent link
sam detweiler (12.5k6194201) | answered Aug 15 '16, 2:00 p.m.
I think you have to make two calls, size=1, sort = old to new, and sort = new to old.

Shaule Sachs commented Aug 15 '16, 2:01 p.m.

 Where do I place those modifiers?

Your answer

Register or to post your answer.