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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
Jacky_2022
New Member

Output tracking information from same day docu entry

Hi all,

 

I am an absolute rookie in Power BI and I don't know what to do with the following case.

 

My over all goal is to make a table visual that shows what type of tracking information records how many applications from employees. Like this:

LinkedIn Jobs       12

Google Jobs         54
....

Jacky_2022_0-1671529515910.png

 

I wanted to write a measure to return tracking information of an employee dataset. I want to output the tracking information that was documented on the same day as a received application.

A received application can be recognized by the ID's "D5D5" und "6FF5" in Prospect_entry[CreatedBy]. The measure for this has already been written successfully:

 

Application = CALCULATE(COUNT(MARKETING[ID_employee]),

FILTER(Prospect_entry,DATEDIFF([Creationdate],[Minimum Earliest date: CreatedAtDate per ID_employee],DAY)>=1),
Prospect_entry[new_ma_status_Status] = "assigned by KAM",
FILTER(Prospect_entry,Prospect_entry[CreatedBy] = "D5D5" || Prospect_entry[CreatedBy] = "6FF5")

 

Now I am missing the Tracking Information component. I had the following approach, which unfortunately did not give me any results.

 

TrackingInfo: Application =

var prospect_entrydate= SELECTEDVALUE(Prospect_entry[CreatedAtDate])

 

var result = CALCULATE(COUNT(MARKETING[ID_employee]),

FILTER(Prospect_entry,DATEDIFF([Creationdate],[Minimum Earliest date: CreatedAtDate per ID_employee],DAY)>=1),
Prospect_entry[new_ma_status_Status] = "assigned by KAM",
FILTER(Prospect_entry,Prospect_entry[CreatedBy] = "D5D5" || Prospect_entry[CreatedBy] = "6FF5"),
FILTER(employeeTracking, employeeTracking[CreatedAtDate] = prospect_entrydate))

 

return result

 

Let me know, if you need any further information.

Thanks for your help!

2 REPLIES 2
v-yueyunzh-msft
Community Support
Community Support

Hi , @Jacky_2022 

According to your description, after you added filter expression in your oringinal dax formula ,the measure did not give any result now.I  found you use the selectedvalue() function for the newly added filter expression.Based on my experience, the selectedvalue() function can only output value when it's single seleted on the slicer or put in the table chart. So would you like to make sure this first?

For more information about selectedvalue() function , you can refer to :
SELECTEDVALUE function - DAX | Microsoft Learn

 

If this method does not meet your needs, you can provide us with your special sample data and the desired output sample data in the form of tables, so that we can better help you solve the problem.

Thank you for your time and sharing, and thank you for your support and understanding of PowerBI! 

 

Best Regards,

Aniya Zhang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

Hi Aniya,

thanks for your reply. Do you have any idea, which function I could use instead of selectedvalue, when I want to see the specific value of a cell as a result and not an aggregation function. I tried this:

 

TrackingInfo: Application =
var prospect_entrydate = CALCULATE(SELECTEDVALUE(Prospect_entry[CreatedAtDate]), Prospect_entry[new_ma_status_Status] = "assigned by KAM", FILTER(Prospect_entry,Prospect_entry[CreatedBy] = "D5D5" || Prospect_entry[CreatedBy] = "6FF5"))

var is_TrackingInfo = FILTER(employeeTracking, employeeTracking[CreatedAtDate] = Prospect_entry)

var result = CALCULATE(COUNT(Prospect_entry[ID_employee]), is_TrackingInfo,

FILTER(Prospect_entry,DATEDIFF([Creationdate],[Minimum Earliest date: CreatedAtDate per ID_employee],DAY)>=1))

return result
 
I got a result with this measure, but it seems to be not correct. Do you have any idea? I appreciate your help.

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.