web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Extract and compare Da...
Power Automate
Suggested Answer

Extract and compare Dates from PBI

(2) ShareShare
ReportReport
Posted on by 9
Hi All
 
JOB-  is to compare the date in database with latest date and if the database do not has the latest date data then do not send email or if it has then the flow will extract pdf and send in email.
PROBLEM- i am trying to extract a date form my power bi tables and compare it with current system date.
 
can some one hep on how to get this done.
 
what i have tried so far-
1. get date as first row from the table in pbi - Run a query against a dataset.
output is a json format
input- (Query text- EVALUATE
LASTDATE(bi_daily_agg_engagement[date]
 
2. compare to get the latest date - from Compore - 
formatDateTime(utcNow(),'ddd,dd-MMM-yyyy')
 
3. not sure on how to convert the json output from pbi to a date and also compare with latest system date.
 
Kindly share more insights on this help.
 
Categories:
I have the same question (0)
  • Nived_Nambiar Profile Picture
    18,136 Super User 2026 Season 1 on at
    Hi,
     
    for that you have to extract the date from that json output. Could you show how the json output as per step 1 looks ?
     
    Thanks & Regards,
    Nived N 
    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs
     Found my answer helpful? Please consider marking it as the solution!
     Your appreciation keeps me motivated. Thank you!

     
  • lbendlin Profile Picture
    8,638 Super User 2026 Season 1 on at
    EVALUATE needs to return a table.  At the very minimum your query needs to be 
     
    EVALUATE { LASTDATE(bi_daily_agg_engagement[date]) }

    Your date comparison should follow the ISO-8601 format.
  • Vijay Tailor Profile Picture
    2,961 on at
    Hi ,

    even you can use parseJSON action then do the comparison.

    Thanks,
    Vijay   
  • PK-02090343-0 Profile Picture
    9 on at
    reply to  Nived_Nambiar:
    attached is the json output. Can you help share how to get the data form the out put and compare it with the local system date on a daily basis? 
  • PK-02090343-0 Profile Picture
    9 on at
    reply to lbendlin :
    how can i get a date as output from the PBI table ?
    would be really helpful if you could share more on to your suggestion.

    reply to Vijay Tailor :
    can you share more on how to use the data in parseJSON and compare to local system date ? as the output from PBI and system are in different format.
  • Suggested answer
    Nived_Nambiar Profile Picture
    18,136 Super User 2026 Season 1 on at
    Hi,
     
     
    To get the date from json output stored in compose action - try this expression
     
    if the compose action name is Compose, then 
     
    outputs('Compose')?[0]?['tables']?[0]?['rows']?['bi_daily_agg_engagement[date]']
     
    But the date value which you get from the above expression should the format the utc date and also both dates should be of same timezone.
     
    So assuming both dates are of same timezone, then it you can convert the utc date format in following expression
     
    formatDateTime(utcNow(),'yyyy-MM-ddTHH:mm:ss')
     
     
    Thanks & Regards,
    Nived N 
    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs
     Found my answer helpful? Please consider marking it as the solution!
     Your appreciation keeps me motivated. Thank you!

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 557

#2
Valantis Profile Picture

Valantis 328

#3
David_MA Profile Picture

David_MA 264 Super User 2026 Season 1

Last 30 days Overall leaderboard