cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ezequiel
Microsoft
Microsoft

Combine conditions on filter array

Hi

 

I'm trying to combine two AND on the following:

 

@And(equals(item()?['_me_areaoptionset_label'], 'United States'),greater(item()?['msevtmgt_eventstartdate'],utcnow())

 

but I'm getting the following error:

 

There is an unterminated string literal at position 28 in 'msevtmgt_eventstartdate gt ''.

 

Can you help me to understand what is going wrong?

 

Thanks

 

Ezequiel 

4 REPLIES 4
Expiscornovus
Super User
Super User

Hi @ezequiel,


It looks like you are missing a closing ). And I would also say you probably needs some formatting in your utcNow funciton as well.

 

Can you try this instead:

@and(equals(item()?['_me_areaoptionset_label'], 'United States'),greater(item()?['msevtmgt_eventstartdate'], utcNow('yyyy-MM-dd')))

 

Note: you might need to change the formatting to the formatting you are using in that eventstartdate though.

Thanks for the reply. I tested it with your suggestion, but I'm still getting the error

"There is an unterminated string literal at position 28 in 'msevtmgt_eventstartdate gt ''."

 

the format of the eventstartdate is correct as yyyy-MM-dd

 

Any suggestion?

 

Thanks

 

Ezequiel

Expiscornovus
Super User
Super User

Hi @ezequiel,


Can you share a couple of screenshots of your flow setup? 

v-bofeng-msft
Community Support
Community Support

Hi @ezequiel :

Maybe you could try:

@And(
  equals(item()?['_me_areaoptionset_label'], 'United States'),
  greater(formatDateTime(item()?['msevtmgt_eventstartdate']),utcnow())
)

If this formula not work,could you please tell me:

  • What is msevtmgt_eventstartdate's  data type?
  • Could you provide a demo of the data source?

Best Regards,

Bof

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Users online (1,986)