Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > Sort by multiple date fields View modes: 
User avatar
Member
Member
jacques.honore-gmail - 5/7/2012 4:12:30 AM
   
Sort by multiple date fields
Hello,

I have a repeater that list Blog Posts and events in the same webpart. I am trying to sort them using two different date field. BlogPostDate and EventDate.

Does anyone have a clue of what I should input in "Order by expression".

I tried to input "COALESCE (EventDate, BlogPostDate)" which is supposed to return the first non-empty result but it doesn't work.

Thank for your support.
Cheers,
Jacques

User avatar
Kentico Support
Kentico Support
kentico_janh - 5/9/2012 9:10:04 AM
   
RE:Sort by multiple date fields
Hello,

I am afraid, you won't be able to do that by standard repeater. I suggest you to write you own custom SQL query (Site Manager -> Development -> Document types -> <document type> -> Queries) and use Repeater with custom query web part instead of the Repeater one.

Best regards,
Jan Hermann