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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
jdelacrettaz
Frequent Visitor

filter between the first day of the month to the current date power bi

Good afternoon, I have a table where in a column frame with a 1 the working days and with 0 on Sundays. My question is the following, I want to show in a card the number of days that go of the month in process but without using the filter date, I want that it is not modified and it goes increasing while the days pass. Always taking the first of the month today. Is there any formula to use?

 

iam using this formulas but give me all days that have the month 

Cantidad de dias = SUMX (
FILTER (
fecha_act,
DATE ( YEAR ( fecha_act[fecha] ), MONTH ( fecha_act[fecha]), 1 )
= DATE ( YEAR ( TODAY () ), MONTH ( TODAY () ), 1 )
),
fecha_act[Dias Utiles]
)
 I use this formula but it gives me back the amount of useful days that I will have in the month and I want it to go away for the day that I am
1 ACCEPTED SOLUTION
v-cherch-msft
Employee
Employee

Hi @jdelacrettaz 

Please check below measure.Attached sample file for your reference.

Measure = 
CALCULATE (
    COUNT ( fecha_act[Useful Days] ),
    FILTER (
        fecha_act,
        fecha_act[Useful Days] = 1
            && YEAR ( fecha_act[Date] ) = YEAR ( TODAY () )
            && MONTH ( fecha_act[Date] ) = MONTH ( TODAY () )
            && fecha_act[Date] <= TODAY ()
    )
)

Regards,

Community Support Team _ Cherie Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-cherch-msft
Employee
Employee

Hi @jdelacrettaz 

Please check below measure.Attached sample file for your reference.

Measure = 
CALCULATE (
    COUNT ( fecha_act[Useful Days] ),
    FILTER (
        fecha_act,
        fecha_act[Useful Days] = 1
            && YEAR ( fecha_act[Date] ) = YEAR ( TODAY () )
            && MONTH ( fecha_act[Date] ) = MONTH ( TODAY () )
            && fecha_act[Date] <= TODAY ()
    )
)

Regards,

Community Support Team _ Cherie Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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