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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Thiagops
Helper II
Helper II

Column with information from another table

Good morning,

I need to create a column in the CUSTOMERS (WALLET) table.
This column will pull information from the PEDIDO_VENDA table (Date of the last quote made by the customer).
I can't relate the two tables because it generates ambiguity with another table (SELLERS).
Follow the formula below and screen prints:

 

Data da última cotação =
CALCULATE(
MAXX ( RELATEDTABLE ( PEDIDO_VENDA ), PEDIDO_VENDA[PV_DATA_PEDIDO] ),
PEDIDO_VENDA[PV_TIPO] = "COTAÇAO",
PEDIDO_VENDA[CFOP_CODIGO] = "5102" ||
PEDIDO_VENDA[CFOP_CODIGO] = "6102"
)

 

Thiagops_0-1677840506215.png


In the case below, it should pull the most recent date (09/09/2022), but the result comes out 03/02/2023

Thiagops_1-1677840721053.png

 

1 REPLY 1
Adamboer
Responsive Resident
Responsive Resident

Based on the provided information, it seems like there may be an issue with the formula used to pull the information from the PEDIDO_VENDA table. Here are some steps you can try to troubleshoot the issue and get the correct date:

  1. Double-check that the formula is entered correctly with no typos or missing information.
  2. Verify that the PEDIDO_VENDA table contains the correct date for the last quote made by the customer. If the date in the table is incorrect, it will not pull the correct date in the CUSTOMERS (WALLET) table.
  3. Check if there are any filters applied to the data that may be affecting the results. Make sure that there are no filters on the PEDIDO_VENDA table that are causing it to exclude the most recent date.
  4. If the issue persists, consider seeking assistance from a database administrator or specialist who can provide further troubleshooting and support.

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.