Making the sql in eventsresult fabulus as requested by Probeus