query
10 TopicsDax Query Consumed Memory 1063 MB,exceeded
Hi Guys, in power bi desktop I got en error : Visual has exceeded available resources I have run Performance Analyser and after running dax queries I got: Resolve the error to see results Resource Governing: This query uses more memory than the configured limit. The query — or calculations referenced by it — might be too memory-intensive to run. Either reach out to your Analysis Services server administrator to increase the per-query memory limit or optimize the query so it consumes less memory. More details: consumed memory 1063 MB, memory limit 1024 MB. I have used Run in Dax query view. This is my code: DEFINE VAR __DS0FilterTable = FILTER( KEEPFILTERS(VALUES('Dim_Date'[Date])), AND('Dim_Date'[Date] >= DATE(2025, 4, 1), 'Dim_Date'[Date] < DATE(2025, 5, 1)) ) VAR __DS0Core = SUMMARIZECOLUMNS( ROLLUPADDISSUBTOTAL( ROLLUPGROUP( 'Dim_EA_SavingPlans'[CommitmentAmountPerDay], 'Dim_EA_AmortizedCosts_DiscountPlans'[PricingModel], 'Dim_EA_AmortizedCosts_DiscountPlans'[ResourceLocationNormalized], 'Dim_EA_AmortizedCosts_DiscountPlans'[OfferId], 'Fct_EA_AmortizedCosts'[CostInBillingCurrency] ), "IsGrandTotalRowTotal" ), __DS0FilterTable, "Wastage_Amount", 'MeasureTable'[Wastage Amount], "Commitment_Amount_Per_Day_With_OnDemand", 'MeasureTable'[Commitment Amount Per Day With OnDemand], "Percent_Commitment_Day_Has_PricingModel", 'MeasureTable'[Percent Commitment Day Has PricingModel], "Wastage___in_Total_Has_Pricing_Model", 'MeasureTable'[Wastage % in Total Has Pricing Model], "Sum_of_Amortized_Cost__TREATAS_", 'MeasureTable'[Sum of Amortized Cost (TREATAS)] ) VAR __DS0PrimaryWindowed = TOPN( 502, __DS0Core, [IsGrandTotalRowTotal], 0, 'Fct_EA_AmortizedCosts'[CostInBillingCurrency], 1, 'Dim_EA_SavingPlans'[CommitmentAmountPerDay], 1, 'Dim_EA_AmortizedCosts_DiscountPlans'[PricingModel], 1, 'Dim_EA_AmortizedCosts_DiscountPlans'[ResourceLocationNormalized], 1, 'Dim_EA_AmortizedCosts_DiscountPlans'[OfferId], 1 ) EVALUATE __DS0PrimaryWindowed ORDER BY [IsGrandTotalRowTotal] DESC, 'Fct_EA_AmortizedCosts'[CostInBillingCurrency], 'Dim_EA_SavingPlans'[CommitmentAmountPerDay], 'Dim_EA_AmortizedCosts_DiscountPlans'[PricingModel], 'Dim_EA_AmortizedCosts_DiscountPlans'[ResourceLocationNormalized], 'Dim_EA_AmortizedCosts_DiscountPlans'[OfferId] Can anybody advice what is wrong with my query? Best, JacekSolved872Views0likes3CommentsImage limitation in Power Bi query
Is there a limit to the number of images that can be expanded in Power Bi query? I have processed 12 images by clicking the expand in image fied. The query does not display the expand icon in field any more for the other images I need to process in the report.Solved827Views0likes4Commentscontains a value
Hello all I am new to DAX and learning thing as I go. I am creating a measure where I wish to give me a count of issues based on certain criteria Open Issues Platform = CALCULATE(COUNTROWS('Jira-Extract-Live'), 'Jira-Extract-Live'[All Labels]="Platform" What I have now found is that my All Labels column contains other values and hence is not matching so my question is (and apolgise if really simply) can the = be substituted to represent 'contains'? So my query would be the same but the ask on the All Labels column would be contains "Platform"? Thanks JSolved1KViews0likes2CommentsChart with last 4 weeks' data and secondary chart with just last week's data
Hello! This is my first forum post so please be understanding if I post too much info, I want to be 'easy' to help 🙂 I am trying to show 4 weeks of data in a chart, which is easy, but on the same power bi page in a different chart, show the most recent week worth of data too. I have the data automatically uploading from a database source. The data I have currently looks like this in my query, with the current chart showing the equipment name on x axis, and the OEE percentages on Y. There is a slider that is linked to Shift ISO column so that the last 4 weeks of data can be displayed. Is there any way to make a chart that only shows the last week's worth of data based on the time of accessing the power bi? thank you!Solved541Views0likes1CommentDAX Query optimization
Hey, Looking for some query optimization tips. I am having query as below, which is performing in around 3000ms (979 FE, 1766 SE). How would you guys change this query in order to get better report response time :)? MEASURE [%] = IF ( ( SUM ( Number ) / ( DISTINCTCOUNT ( Date ) * 5 ) ) > 1, 1, SUM ( Number ) / ( DISTINCTCOUNT ( Date ) * 5 ) ) Thanks in advance!Solved766Views0likes2CommentsPower BI: How to generate a table of daily web traffic reports? Help?
I pull data from a digital site via an API into Power BI for reporting. The API has an analytics endpoint for a web traffic report, but it is ONLY an aggregate report, as in it won't make one call and separate it into individual days. I can call (below) to show the traffic for any particular day. I would like to write a query to use this API call to generate a table where each row is the traffic for a day starting at 2022-05-15 until whatever the current day is. So a row for 05-15, 05-16, 05-18, until the current date. Anyone have a suggestion? https://api.somewhere.tv/analytics?type=traffic&from=2022-05-15&to=2022-05-15Solved852Views0likes2CommentsLoop through two columns to get max result entries
I'm in need of a solution, which I'm sure is possible, but beyond my current PowerBI skill-set. Thanks in advance for your help. I have a table with 4 columns: [Row ID] - a generic row# of the table [Entry No.] - link to an entry in an inventory table [Entry No. (IN)] - if the [Entry No.] was an inbound entry (an increase to inventory) then identifies the same as [Entry No.] [Entry No. (OUT)] - if the entry was an outbound entry (an decrese to inventory) then identifies the same as [Entry No.] The purpose of the table is to trace the moment of inventory transactions through the system - from the initial inbound/increase entry through to whe the inventory left/decreased. Below are some examples of increasing complexity: Example 1 [Entry No.] 1 is an increase in inventory of 50 [Entry No.] 2 is a decrease in inventory of 50 linked to [Entry No.] 1 Required result I need is Example 2 - slightly more complex same as example 1, but this time two entries [Entry No.] 2 and 3 have 25 each consuming the original 50 Required result I need is Example 3 - slightly more complex again same as example 1 and 2 except this time [Entry No.] 2, of which 25 came from [Entry No.] 1 gets consumed again into [Entry No.] 4 and 5 at a quantity of 10 and 15 respectively. [Entry No.] 3 also goes on to be consumed into [Entry No.] 6 Required result I need is Example 4 - another slightly more complex scenario 25 of [Entry No.] 1 goes into [Entry No.] 2 which in-tun goes into [Entry No.] 3 which in-turn goes into [Entry No.] 4 which finally gets split into [Entry No.] 5 and 6. Note 25 of [Entry No.] 1 is still yet to be used, so this needs to show also. Required result I need is Hopefully from these examples below you can see the table I'm trying to build could be described as: "for each inbound entry (defined as where [Entry No. (IN)] not blank AND [Entry No. (OUT)] = 0) I need to know where and in what quantity it has ended up." Where it ended up will always be the MAX([Entry No. (OUT)]). However it's not a rule that the [Entry No. (IN)] is always less than the [Entry No. (OUT)], sometimes (IN) will be higher than (OUT), however the MAX([Entry No. (OUT)] will always be the "where it went" for the higher (IN). example: Required result I need is You'll see fomr the examples also that any quantities yet to be fully used/consumed should also be visible. below is a larger set of example data and expected results. Row ID Entry No. Entry No. (IN) Entry No. (OUT) Quantity 1 1 1 0 50 2 2 1 2 50 3 3 3 0 50 4 4 3 4 25 5 5 3 5 25 6 6 4 6 13 7 7 4 7 12 8 8 8 0 50 9 9 8 9 30 10 10 9 10 15 11 11 9 11 15 12 12 10 12 7 13 13 10 13 8 14 14 11 14 10 15 15 15 0 50 16 16 15 16 10 17 17 15 17 10 18 18 15 18 10 19 19 16 19 5 20 20 17 20 7760Views0likes2CommentsHelp modifying a query
I am currently using a query that pulls data from a server for a selected date range. I am trying to edit it to pull three years worth of data in the following manner: 1-1-2019 thru 4-4-2019 1-1-2020 thru 4-4-2020 1-1-2021 thru 4-4-2021 I tried duplicating and editing the date portion , but that only gets me a token identifier error. Do I need to duplicate the entire statement three times? Hoping someone can help. Her is the date portion of the query- (d.timedown between '2019-01-01' and '2019-4-4')"]),850Views0likes4CommentsTables with Two Key
Hello, I Have two tables the first includes the Revenue Details and the other one claims, the tables looks something similar to the below, Medical Record No Visit Number Visit Date Name Claim ID Phamracy Claim ID Invoice Amount XX VAN100 1 Jan 20 John CL1000 150 YY VAN200 1 Jan 20 Adam CLP2000 250 ZZ VAN300 5 Jan 20 Lawrance CL1500 CLP2500 500 And the other table Include the the Claims Details as follow: Claim ID Payment Date Payment Amount CL1000 2 Feb 20 150 CLP2000 5 Feb 20 200 CL1500 3 March 20 200 CLP2500 7 Feb 20 300 Im trying to create a relation between the two tables but since there is two coulmns in the first table as the primary key and only one in the second table i could not get, im looking to build a summary that looks like Visit Number ( Table 1 ) Claimed Amount (Table 1) Paid Amount (Table 2 ) VAN100 150 150 VAN200 250 200 VAN300 500 5005.2KViews0likes7CommentsTopN Customers by Revenue filtered by Region, Country and, Reporting Unit
Hi, I m new to DAX and Power BI and not able to make out reason for inconsistent result. There are slicers for Region, Country and, Reporting Unit in Power BI report and I need to show top 5 customers from TodaysTable data based on the selection made. Table structure: HistoryTable - with Region, Country, Reporting Unit, Revenue, & CombinationKey (REG + COUNTRY + RU) TodaysTable - with Region, Country, Reporting Unit, Customer, Customer ID, Revenue & CombinationKey (REG + COUNTRY + RU) MapTable - Active Relationship, Both directions on CombinationKey - DISTINCT(ALL(HistoryTable [CombinationKey], HistoryTable [Region], HistoryTable [RU], HistoryTable [Country])) I created 2 Measures in TodaysTable Todays Revenue = SUMX(TodaysTable , TodaysTable [Net Order Value]) Rank of Customer = RANKX(ALLSELECTED(TodaysTable [Customer]),[Todays Revenue],,DESC,DENSE) and applied filter Rank of Customer <=5 in the report. While this shows the result correctly when I have only Customer and Todays Revenue as columns in the table. However, if I include Customer ID/ Region/ Country number of results shown just multiplies and I noticed that the Rank is repeating (multiple rows shows up as having Rank 1 while having different Revenues !!!) . I m unable to understand this behavior. It would be nice if someone could help me with correct DAX expression. that would enable me to show only 5 customers based on max revenue with additional fields (Region, Country, Customer ID). Also, I would like to know if this can be achieved with a single DAX expression. Thanks in advance.Solved5KViews0likes1Comment