Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
LinhNguyen
Helper II
Helper II

Import data from SAP - How to choose latest date

Hi all,

 

I have a big table in SAP BW with a lot of columns. It times out whenever I try to load data into PowerBI. I'm trying to filter data to the latest report date (2020/03/14 in the example code below) to reduce the amount of data queried from SAP BW. Could you let me know if there's a way to make this date filter dynamic (get only the latest date).

 

I would also appreciate any suggestion on how to import large data with lots of columns from SAP. (I have tried filtering then appending together again but that way, I'll create a lot of tables)

 

= Cube.Transform(#"ZSD_O08/ZSD_O08_Q0001",
{
{Cube.ApplyParameter, "[!V000001]", {"[ZRPTDATE].[20200314]", "[ZRPTDATE].[20200314]"}},
{Cube.ApplyParameter, "[!V000005]", {{}}},
{Cube.ApplyParameter, "[0SALEORG]", {{"[0SALESORG].[1000]"}}},
{Cube.ApplyParameter, "[0S_PLANT]", {{"[0PLANT].[1000]"}}},
{Cube.AddAndExpandDimensionColumn, "[ZRPTTIME]", {"[ZRPTTIME].[LEVEL01]"}, {"Report Time.Report Time Level 01"}},
{Cube.AddAndExpandDimensionColumn, "[ZCUSTNZ1]", {"[ZCUSTNZ1].[LEVEL01]"}, {"Sales Manager Code.Sales Manager Code Level 01"}},
{Cube.AddAndExpandDimensionColumn, "[0SCHD_CATEG]", {"[0SCHD_CATEG].[LEVEL01]"}, {"Schedule Line Type.Schedule Line Type Level 01"}},
{Cube.AddMeasureColumn, "Original Order Quantity", "[Measures].[ZKF_ZSDO08_ORGOQ]"},
{Cube.AddMeasureColumn, "Unconfirmed Backlog Value in USD", "[Measures].[ZKF_ZSDO08_UNCONFBKLVU]"}
})

1 ACCEPTED SOLUTION
v-juanli-msft
Community Support
Community Support

Hi @LinhNguyen 

Do you connect to SAP with Power BI via import or direct query mode?

Firstly, you could check the ideas below:

https://community.powerbi.com/t5/Desktop/SAP-BW-BEx-Dynamic-Parameters/td-p/464624

https://community.powerbi.com/t5/Desktop/Dynamic-Parameters-with-SAP-BW-BEX/td-p/623453

 

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

1 REPLY 1
v-juanli-msft
Community Support
Community Support

Hi @LinhNguyen 

Do you connect to SAP with Power BI via import or direct query mode?

Firstly, you could check the ideas below:

https://community.powerbi.com/t5/Desktop/SAP-BW-BEx-Dynamic-Parameters/td-p/464624

https://community.powerbi.com/t5/Desktop/Dynamic-Parameters-with-SAP-BW-BEX/td-p/623453

 

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.