circular
5 TopicsSummarizing data to find redeployments/repeated stock transfers
Hi all, I am trying to find the quantity of stock that is redeployed (dispatched again to other DC) from a DC after being received. The end requirement should look similar to this table. The material 11111 with BatchID ABC was first sent from 8881 to 7771 (Quanity 150). After being received at 7771, it was again sent to 4451 (Quantity 100) which isn't advised. (In case this view is not possible, please propose another view that conveys similar information) MaterialID BatchID Origin Destination Quantity 2_Origin 2_Destination Dwell Time Redeployed Quantity 11111 ABC 8881 7771 150 7771 4451 22 100 The data contains two transaction tables: 1. TransportDetails 2. MaterialDetails TransportDetails_Joined table contains the list of transport orders with material, source, destination & date details. First 7 columns from OrderID to Quantity give details about the primary transport order, colums 8 through 14 give details about the redeployment (the material is sent to another location after being received.) For e.g., looking at the first row we see that material 11111 is moved from 8881 to 7771, and then sent to 4451 from 7771. (This is a wide table with 14 columns, please scroll horizontally) TransportDetails_Joined OrderID MaterialID Origin Destination ShippingDate ReceiptDate Quantity 2_OrderID 2_MaterialID 2_Origin 2_Destination 2_ShippingDate 2_ReceiptDate 2_Quantity 3123456 11111 8881 7771 09/26/2023 09/28/2023 150 3812345 11111 7771 4451 10/20/2023 10/24/2023 100 3123456 11111 8881 7771 09/26/2023 09/28/2023 150 3900001 11111 7771 6641 10/29/2023 11/02/2023 480 This TransportDetails table was created by me after doing a self join of the following original TransportDetails table with a few conditions like (left MaterialID = right MaterialID), (left destination = right source), (left ReceiptDate < right ShippingDate) . OrderID MaterialID Origin Destination ShippingDate ReceiptDate Quantity 3123456 11111 8881 7771 09/26/2023 09/28/2023 150 3123456 11111 8881 7771 09/26/2023 09/28/2023 150 3812345 11111 7771 4451 10/20/2023 10/24/2023 100 3900001 11111 7771 6641 10/29/2023 11/02/2023 480 3750001 11111 2321 5420 08/08/2023 08/10/2023 250 3780002 11112 3593 6750 07/07/2023 07/10/2023 125 MaterialDetails table provides information about the batch that was transferred in each OrderID. MaterialDetails OrderID MaterialID BatchID Destination PostingDate Quantity 3123456 11111 ABC 7771 09/25/2023 150 3812345 11111 ABC 4451 10/19/2023 100 3900001 11111 GGG 6641 10/28/2023 480 I want to create a measure/calcualted column or some other method to summarize data such that it indicates the actual quantity redeployed when the BatchIDs match. We need to achieve this using MaterilDetails table and TransportDetails_Joined or the original TransportDetails table. We can create any number of intermediate tables if required. The final table should look something like this. Redeployed Quantity needs to be found for each material & batchID combination. Dwell time is the time period between the first transfer's receipt date and the second transfer's shipping date = (2_ShippingDate) - (ReceiptDate) (In case this view is not possible, please propose another view that conveys similar information) MaterialID BatchID Origin Destination Quantity 2_Origin 2_Destination Dwell Time Redeployed Quantity 11111 ABC 8881 7771 150 7771 4451 22 100 I've been trying so hard to summarize the data and can't find a neat approach. Please help me with creating this summary. Any help is greatly appreciated. Thanks in advance!450Views0likes1CommentReplication of an Excel file calculation - circular dependency issue
Hi Everyone, I would like to replicate a calculation (quite simple) in Excel in a PowerBi file. I've tried several times but have an issue of circular dependency. I have not been able to break it so far so i would appreciate any help/ideas on how to model the Excel in PowerBi. Here below the Excel file: https://we.tl/t-YYGL9Dn0l5 Many thanks in advance for your help!Solved742Views0likes2CommentsCircular relationship
I have three tables: Person Skills: {Person A: Skill A, Skill B, ... ; Person B: Skill B, ...} Person Roles: {Person A: Role A; Person B: Role B} Role Skills: {Role A: Skill B, ... ; Role B: Skill B, ...} I need to answer question: what skills necessary for a role does a person have in PowerBI. It creates a circular relationship because firstly I need to filter Person Skills by person, then person roles by person, then role skills by role, and finally person skills by skills from selected role.. Could someone help me to solve this?302Views0likes0CommentsACTUAL vs TARGET
Hello I need to compare actual sales vs target and when target is achieved I need to be able to write "[Target Name] Achieved" Here's my model: DIMS contains my items per year and per group (REQUESTED_ITEM_KEY is unique for a year and a group) In Sales, I keep track of each sale action (quantity not needed righ now, assume it to be 1) And a sale action has a status OK/NOK A target is identified by a Target Label (that is the concatenantion of the ID, GROUP, and YEAR) A target definition concerns several Items (several REQUESTED_ITEM_KEY) and for each item I can specify the requested quantity for the target to be achieved; only if all the lines concerning a Target are achieved, the target is achieved too When checking for target compliance, I only need to take from Sales, those lines for which the status is "OK" The DIMS table has been built by extracting all the REQUESTED_ITEMS available in the other two table, by GROUP and YEAR I am able to : Count for a TARGET Label, and a REQUESTED ITEM, the corresponding lines in SALES for which the Sales Rep have a Status="OK" But When I compare this value with the REQUESTED QUANTITY I get a CIRCULAR DEPENDENCY At the end I would like to build a matrix as the one below Thank You!685Views0likes1CommentCircular relationship
Hello, I´m creating a new Report and need to create a relationship between the Date and Customers tables to calculate de number of Customers whose registration date is equal to the selected date. I can´t create this relationship because this causes a circular relationship. Can you help me to solved this problem?Solved9.9KViews0likes5Comments