Filtering a query by a custom date field

Hi, I’m trying to write a loop that filters a custom post type by a custom date field, and struggling to get it to work. The CPT represents running races and has a field (date and time of the race) and I want a list of upcoming races (i.e. next 5 after today). My CPT is setup using the “Toolset Types” plugin and printing the raw values it looks like a timestamp field.

I’ve tried this but it simply lists the earliest 5 events, not ones that are after today:

<Loop type=events custom_date_field=wpcf-start_date custom_date_field_format=timestamp custom_date_field_type=datetime custom_date_field_value=current custom_date_field_compare=after_inclusive order=asc orderby_field=wpcf-start_date count=5>
  <a href="{Field url}"><Field title/></a> <Format date="Y-m-d H:i"><Field wpcf-start_date/></Format><br/>
</Loop>

(note that if I change custom_date_field_compare from after_inclusive to after it gives no results at all)

Another option I tried was to treat the field as a number and filter by timestamp value, but that doesn’t give any results at all (whether custom_field_type is timestamp or number):

<Loop type=events custom_field=wpcf-start_date custom_field_type=timestamp custom_field_compare=more_than custom_field_value="{Date format=timestamp}" order=asc orderby_field=wpcf-start_date count=5>
  <a href="{Field url}"><Field title/></a> <Format date="Y-m-d H:i"><Field wpcf-start_date/></Format><br/>
</Loop>

Has anyone got any ideas what I am doing wrong please, and how to get L&L to work properly for this kind of thing?

Many thanks,

Chris

A slight update…

The following code outputs all events and the nested If condition correctly calculates whether that event is in the future, so I guess I could use that as a nasty inefficient work-around. However what I really need is to be able to do the equivalent of the If condition in the Loop condition itself, but every possible way of doing this I’ve tried either returns all results or no results?

<Loop type=events order=asc orderby_field=wpcf-start_date count=20>
  <a href="{Field url}"><Field title/></a><br/>
  formatted: <Format date="j F Y g:i a"><Field wpcf-start_date/></Format><br/>
  raw: <Field wpcf-start_date/><br/>
  after today?
  <If field="wpcf-start_date" after="{Date}">
    Yes
  <Else/>
    No
  </If>
  <br/><br/>
</Loop>