Forum Discussion

CJKPowerBI's avatar
CJKPowerBI
Icon for Helper I rankHelper I
3 years ago
Solved

formula in excel make it in PowerBi

Hello all,   i have the below formula in excel which basically checks today's date and if before this month 23rd day then it puts the 15th of this month, if todays date is more than 23rd of this mo...
  • tamerj1's avatar
    tamerj1
    3 years ago

    CJKPowerBI 

    Please try

    Amount to be paid on =
    IF (
        OR ( [Charge] = "Text 1", [Charge] = "Text 2" ),
        IF (
            DAY ( [Transcation Date] ) <= 23,
            DATE ( YEAR ( [Transcation Date] ), MONTH ( [Transcation Date] ) + 1, 15 ),
            EOMONTH ( [Transcation Date], 1 ) + 15
        ),
        [Transcation Date]
    )