I’m want to use the title of a post object field to sort the results of a query but currently it seems to use the postid rather than the title:
‘orderby’ => ‘meta_value’,
‘meta_key’ => ‘raceyear’,
‘order’ => ‘DESC’,
This make sense knowing how the data is stored but was wondering if it were possible to use the post title instead somehow?
You cannot sort of the title of the post object. The only thing that ACF stores about the post object field is the ID. The same principle applies for something like this as I posted about repeater sub fields here https://acfextras.com/dont-query-repeaters/
basically what you need to do is to create an acf/save_post filter, get the post object field and save the title of that post object as custom meta value associated with the post you want to be able to sort.