0

We store data regarding Scrum sprint retrospectives in a SharePoint list.

I have to create a chart for visualizing this information (which is not part of this topic/problem), so I need to somehow extract the list information in order to transform/work with it in a different environment.

In this case the environment will be a webspace in which I utilize php/js and amCharts to create charts.

Now, for the chart to be filled with data I need to be able to actually access the data and for this purpose an XML(-like) format would be best for me.

I found out that SharePoint actually provides an REST API to "export" lists to XML with the following link:

https://sharepoint.portal.XXXX/public/YYY/_vti_bin/owssvr.dll?Cmd=Display&List=%7B812FC713-F916-4284-B50F-2EC3B8E80C98%7DQuery=*&XMLDATA=TRUE

Normally the problem of filling the chart would now be history, as I could just parse the provided XML information with JavaScript, inject it into the chart and be done with it.

However, when looking at the XML output I realized that all the headings from the list were missing, i.e. only the actual data remained, which is rather useless without context (the headings).

In my case that currently means that I cannot map the feedback data to a specific Scrum sprint retrospective. I just got a big list of feedback for all retrospectives that ever happened and were put down in writing to the SP list.

Therefore I can't really create a graph with this data, as I couldn't make any distinction of cases.

Does anyone know if there is a way to use this XML export function via the SP REST API with included headings? I would appreciate any help and hints regarding this matter.

Attached you find sample screenshot of the table and the corresponding output in the XML file generated by SharePoint:

Table:

enter image description here XML:

<z:row ows_Art='negativ' ows_A='AAAAAAAAAAAAAAAAAAAAAAAA' ows_B='BBBBBBBBBBBBBBBBBBBBBBB ' ows_Priority='(2) Normal' ows_C='CCCCCCCCCCCCCCCC/>

As you can see, the mapping of this "zrow" to a certain heading and subheading is missing and this mapping would be exactly what I need.

I'd expect something among the lines of this:

<z:heading name="Produkt"
    <z:subheading name="Release"
        <z:rows [....] />
    />
/>

1 Answer 1

1

I found a solution and it's rather simple really...

What I had to do:

  • Create a custom view for my list
  • Edit that view to show the Heading and Subheading (it was shown graphically before, but not as "data")
  • Edit the view so it has a really large "limit results" number. I chose 10000 per page for now (otherwise the created xml file doesn't show all data sets... really silly)
  • Edit my REST query to include the view:

    ..../_vti_bin/owssvr.dll?Cmd=Display&List=%7B812FC713-F916-4284-B50F- 2EC3B8E80C98%7D&View=%7BAAFAA130-33B1-4A21-9E98-C25FECEF79E4%7D&XMLDATA=TRUE

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.