Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago

Not Enough Memory Error

Hello Community, 

 

I have a connection to Amazon Redshift where I am pulling in 7 tables. 

 

I have been using this report for the last 7 months, and it has been working just fine. 2 days ago, I go a memory error error, which I believe is due to an Index that has been added. When I remove that index from the advanced editor, the report refreshes. However, the visualization references the index so when it's deleted it breaks. 

 

Here is the error: "Failed to save modifications to the server. There's not enough memory to complete this operation. Please try again later when there is a more memory available. 

 

Is there a way around this? 

 

Here is the code: 

 

let
Source = 

#"Added Custom" = Table.AddColumn(d365_sql_inventqualityorderlineresults1, "sort_source", each if [testsequence] <10
then
"0"&Number.ToText([testsequence])&[qualityorderid]&Number.ToText(999999.0-[time])
else
Number.ToText([testsequence])&[qualityorderid]&Number.ToText(999999.0-[time])),
#"Sorted Rows1" = Table.Sort(#"Added Custom",{{"sort_source", Order.Descending}}),
#"Added Index" = Table.AddIndexColumn(#"Sorted Rows1", "Index", 0, 1)
in
#"Added Index"

1 Reply

  • Anonymous's avatar
    Anonymous
    Not applicable

    depending on the size of the DB, you're doing a bunch of string concats for what are otherwise numbers to get to an index.  Can you keep an index pure and just a 1,2,3,....?  This will likely save on cycles.

     

    I get the memory errors when I try and do really big operations that are CPU expensive on big DB's....so filter the size of the DB down, or reduce the complexity of the operation. :)