SaaS CMS has officially launched! Learn more now.

Problem with listning of pages with FindPagesWithCriteria

I have a problem with listning pages with FindPagesWithCriteria-function in 4.61 that I have solved but I wounder if anyone know a solution that is better. The problem is that I want to do a simple listning of pages where publishstart < now and (publishstop > now or publishstop == null). This is because the users don't write any value in publishstop when they want the page to last forever. I solved it by doing two listnings and added the answears together because I didn't find any way to have a OR condition in PropertyCriteria. Do anyone know a more pretty way to do this? /Henrik Ståhle
Oct 17, 2007 14:19

Just found the first question I asked in this forum 8 years ago and realized that I do not know if this is possible no.

Does anyone know if you can have OR condition in a PropertyCritera?

Nov 18, 2015 20:42

.Required = false on the criteria?

Nov 19, 2015 0:26

But if I set that on both criteria's wouldn't that make it to return results that does not match any criteria also?

i want something that looks like a representation of a sql like this:

select *

from table

where (a=1 or b=2)

Nov 19, 2015 7:13
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.