We give a complete characterization of a certain class of quasi-Baer rings which have a sheaf representation (by a "sheaf representation" of a ring the authors mean a sheaf representation whose base space is Spec(R) and whose stalks are the quotients R/O(P), where P is a prime ideal of R and O(P)={a epsilon R \ aRs = 0 for some s epsilon R\P}). Indeed, it is shown that a quasi-Baer ring R with a complete set of triangulating idempotents has such a sheaf representation if and only if R is a finite direct sum of prime rings. As an immediate corollary, a piecewise domain R has such a sheaf representation if and only if R is a finite direct sum of prime piecewise domains. Also it is shown that if R is a quasi-Baer ring, then R/O(P) is a right ring of fractions; in addition, if R is neither prime nor essentially nilpotent then R has a nontrivial representation as a subdirect product of the rings R/O(P), where P varies through the minimal prime ideals of R.(C) 2000 Elsevier Science B.V. All rights reserved.