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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
smore
Advocate I
Advocate I

M Language refresh optimization.

 

FruitAmount
Apples5
Oranges2
Cherries10


Is it more efficient to create the above table in Power Query Editor using the "Enter Data" option to manually enter data into a blank table resulting in the autogenerated M code as seen in (Code Block 1) below, or using #table to write a blank query as seen in Code Block 2? Does either method optimize data refresh time?

Code Block 1:

 

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WciwoyElV0lEyVYrViVbyL0rMS08tBvKNwHznjNSiokywgKGBUmwsAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Fruit = _t, Amount = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Fruit", type text}, {"Amount", Int64.Type}})
in
    #"Changed Type"

 


Code Block 2:

 

let  
    Source = #table(  
    type table [Fruit = text, Amount = number],   
        {   
            {"Apple", 5},
            {"Oranges", 2},
            {"Cherries", 10}
        }  
    )  
    
in  
    Source

 



1 REPLY 1
Anonymous
Not applicable

Hi @smore ,

 

Since there is little data, the refresh time may be very close. You may enable Performance Analyzer to find out how each of your report elements, such as visuals and DAX formulas, are performing. Using the Performance Analyzer, you can see and record logs that measure how each of your report elements performs when users interact with them, and which aspects of their performance are most (or least) resource intensive.

Eyelyn9_0-1652065509852.png

 

Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.