Appearing for trial, aim to stand vertically (5)
I believe the answer is:
upend
'stand vertically' is the definition.
(stand something up)
'appearing for trial aim' is the wordplay.
'appearing for trial' becomes 'up' (up before a judge).
'aim' becomes 'end' (both can mean a goal or purpose).
'up'+'end'='UPEND'
'to' acts as a link.
(Other definitions for upend that I've seen before include "Make a turnover" , "Turn on its head" , "Affect greatly" , "Set (something) vertical" , "change things drastically" .)