A man accused of assaulting a police officer, resisting arrest and public disorder has walked free after the sheriff did not turn up.
The case against Scott McMurray, 24, was abandoned after temporary sheriff Ian Duguid failed to appear for a second time.
Such an incident is believed to be a first in Scottish legal history.
Temporary sheriff Duguid is a defence QC and occasionally appears as an advocate depute for the prosecution.
Mr McMurray, from Renfrew, was charged with drinking in a public place, committing a breach of the peace by conducting himself in a disorderly manner, resisting arrest and assaulting a police officer by attempting to head-butt him.
He denied his guilt and the trial at Paisley Sheriff Court, under temporary sheriff Duguid, got under way four months ago.
Due to lack of court time, the case was adjourned until 9 July but put off again when the sheriff did not turn up - no explanation being provided.
When the accused, witnesses and defence agent, Paul Lynch, appeared again on Wednesday the temporary sheriff once more failed to attend.
After it became clear that he was engaged in the High Court, Mr Lynch objected to a further continuation and urged Sheriff Colin Pettigrew to dismiss all charges.
The Crown attempted to have the case adjourned again in a further bid to have the trial concluded.
But Mr Lynch argued that would be unfair to his client, who continued to maintain his innocence, and that the circumstances were "wholly unacceptable".
He stressed that in different circumstances, it was not unusual for the courts to take a very dim view of matters when an accused person, witness - or even a defence solicitor - failed to attend at court when required to do so.
Mr Lynch said it would not be in the interests of justice to further adjourn the trial, particularly as no reasonable explanation had been provided to the court for the sheriff's non-attendance.
After hearing all of the circumstances, Sheriff Pettigrew deserted the case against Mr McMurray "without any hesitation".
Mr McMurray has been told the case against him has now been dropped and cannot be re-raised.