Forum Discussion
ExportTo PowerBI - Api ExportTo
- 11 months ago
I did a test with spaces in the table name and column name:
Table name: ex1 renamed
Column name: Column three
This requeust body produced a filtered result:
Reqused body:
{
"format": "PDF",
"powerBIReportConfiguration": {
"settings": {},
"reportLevelFilters": [
{
"filter": "ex1_x0020_renamed/Column_x0020_three lt 0"
}
]
}
}
Hi
Thanks for the update
With url filter it works
With this string with special characters because my table and columns have the space
&filter=Calendario_x0020_documento/Documento_x0020__x002D__x0020_Anni_x0020_trascorsi_x0020_da_x0020_ultimo_x0020_reload eq 1
But in Api I don't expect to write it this way
Could it be the fault of the spaces on the API too?
Thanks to both of you AmosHersch v-sshirivolu
DavideBono97 did you try the same string with special characters in the API? It might be an issue with the spaces.
- DavideBono9711 months agoHelper I
AmosHersch with this syntax not works
"reportLevelFilters": [
{
"filter": "Calendario?x0020?documento/Documento-x0020?x0020?x002D-x0020?Anni?x0020?trascorsi?x0020?da?x0020?ultimo-x0020?reload eq 1"
}
]I have 200 status code but the filter is ignored
With this syntax i get the same error "Export report filter with empty string provided"
"reportLevelFilters": [
{
"$schema": "http://powerbi.com/product/schema#basic",
"target": {
"table": "Calendario?x0020?documento",
"column": "Documento-x0020?x0020?x002D-x0020?Anni?x0020?trascorsi?x0020?da?x0020?ultimo-x0020"
},
"operator": "Equals",
"values": [1]
}
]- DavideBono9711 months agoHelper I
I try with one table and column that no have space, but not works
In querystring in url on power bi works
"reportLevelFilters": [
{
"$schema": "http://powerbi.com/product/schema#basic",
"target": {
"table": "Operatori",
"column": "Operatore"
},
"operator": "Equals",
"values": ["asd"]
}
]- AmosHersch11 months agoMicrosoft Employee
DavideBono97 the API does NOT work with this schema
"$schema": "http://powerbi.com/product/schema#basic",
No need for any schema, see the example I've shared which is working good. No schema in, and NO json object for the filter.
- AmosHersch11 months agoMicrosoft Employee
I did a test with spaces in the table name and column name:
Table name: ex1 renamed
Column name: Column three
This requeust body produced a filtered result:
Reqused body:
{
"format": "PDF",
"powerBIReportConfiguration": {
"settings": {},
"reportLevelFilters": [
{
"filter": "ex1_x0020_renamed/Column_x0020_three lt 0"
}
]
}
}