Expand columns in slice

Answered

I have an api call set up with a slice pre-determined

slice: {
reportFilters:[{uniqueName: "sl_analysis",}],
rows :[{uniqueName: "customer", sort: "asc"},
{uniqueName: "our_reference"}],
columns:[{uniqueName: "due_year"},
{uniqueName: "due_week"}],
measures:[{uniqueName: "base_os_value", aggregation: "sum", format: "fixed"}]
}

I would like to expand just the columns and not rows (i.e. to show due_weeks) – can you please help with how to set up expandAll.
 
Thanks
Martyn

2 answers

WebDataRocks Team WebDataRocks November 21, 2019

Hello, Martyn,
 
Thank you for your question.
 
Our team would recommend using columns property of the expands object that is placed inside the slice. You can simply expand the desired columns using the following construction:

expands: { 
columns: [{  
"tuple": ["HeirarchyName.FieldUniqueName"]
}]
}

You can learn more about the expands object here.
 
We hope it helps,
 
Kind Regards,
WebDataRocks Team

mshiner November 21, 2019

Thanks for that I’ll give it a go.
 
Martyn

Please login or Register to Submit Answer