web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

Report execution error ( Rendering Output for the report failed due to stream too long.)

(3) ShareShare
ReportReport
Posted on by 458
Hi,
 
I have created a Report in AL where i am merging data from two query objects into one temp table, and using that as my report data item.
 
I have multiple companies in my envoirement,
 
The problem is this report fails to execute with below error. can someone guide me how can i optimize my code to perform well as number of lines going to keep increase in data. and i want this report to perform no matter what. (execution failing at current stage where number of rows are not more than 8,000 rows.) 
 
I have the same question (0)
  • Verified answer
    One And Only Naveen Profile Picture
    458 on at
    After try & error i Found that I was passing Company Picture as data item to RDL Layout and then using it into my report,
    Once I removed it Report started working as expected but I am now stock without company Logo on Report, can some one suggest me some work around for this.
  • Verified answer
    Alexander Drogin Profile Picture
    262 on at
    First of all, the company logo is included in every row of the report. Most likely you want to see the logo in the header, but not every report line. The first improvement is to add company information as a parent dataitem for the temp table and remove all related fields from the details.
    And even besides the logo, I would challenge the number of columns. Are they all really needed? It would be physically impossible to fit all this information in a page. All the fields in the table amount up to approximately 2.5 KB. For 8000 rows, the data size would be around 21 MB. Most likely, not all the lines will have maximum possible length, so the actual volume will be lower. Still it's a big amount, and probably can be significantly reduced simply by removing unnecessary fields.
  • Verified answer
    YUN ZHU Profile Picture
    95,748 Super User 2025 Season 2 on at
    Alexander is right, you only need to generate the Company Logo once, and you don’t need to put it in a loop.
     
    Also, is there detailed error information when you click Copy Details?
     
    Thanks.
    ZHU
  • Verified answer
    One And Only Naveen Profile Picture
    458 on at
     
    Thank you for response & support,

    I have removed it from column and can you please guide me on how to get logo once on header.

    I know i am asking a lot but it would be great.

    @YUN ZHU I follow your blogs as well get lot of knowledge and concept cleared from you blogs.
  • Khushbu Rajvi. Profile Picture
    20,647 Super User 2025 Season 2 on at
    Agree with the previous responses, Company logo does not require repeated generation.
  • Suggested answer
    Khushbu Rajvi. Profile Picture
    20,647 Super User 2025 Season 2 on at
  • One And Only Naveen Profile Picture
    458 on at
    Hello Mentor's 
     
    To get Company Picture and other one time data i applied below method,
     
    Than you for your guidance, I hope this is the correct & efficient way.
     
    Do let me know of your inputs.
     
     dataitem(CMP; Integer)
            {
                DataItemTableView = sorting(Number) where(Number = const(1));
                column(Cmp_Name_RDL; Cmp_Name_RDL) { }
                column(From_date_RDL; From_date_RDL) { }
                column(To_Date_RDL; To_Date_RDL) { }
                column(BU_Filter_RDL; BU_Filter_RDL) { }
                column(Vendor_Filter_RLD; Vendor_Filter_RLD) { }
                column(Logo; Company.Picture) { }
     
                trigger OnPreDataItem()
                begin
                    Company.get;
                    Company.CalcFields(Picture);
                    Cmp_Name_RDL := CompanyProperty.DisplayName();
                    From_date_RDL := From_Date;
                    To_Date_RDL := To_Date;
                    BU_Filter_RDL := Global_Dimension;
                    Vendor_Filter_RLD := Vendor_Filter;
                end;
     
            }
            dataitem(Integer; Temp_Purchase_Reg_Table)
     
            {
                UseTemporary = true;
                DataItemTableView = sorting(Row_No);
     
                column(DocumentType; Document_Type) { }
     
  • Suggested answer
    Suresh Kulla Profile Picture
    50,247 Super User 2025 Season 2 on at
    You can check standard sales report how it is being done, and copy the same logic from there.
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,066

#2
YUN ZHU Profile Picture

YUN ZHU 658 Super User 2025 Season 2

#3
Sumit Singh Profile Picture

Sumit Singh 595

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans