The preliminary issue before us today is whether the court of *377appeals dismissed relator’s complaint pursuant to Civ. R. 12(B)(6) for failure to state a claim for which relief may be granted, or whether it actually granted a Civ. R. 56 motion for summary judgment for the clerk.
The court of appeals’ August 8 entry reflects that it “dismisse[d]” relator’s complaint. However, other considerations suggest that the court actually granted summary judgment. In addition to expressly overruling the clerk’s motion to dismiss on the basis of Civ. R. 12(B)(6) and then ruling sua sponte, the court had before it matters outside the pleadings to decide the clerk’s motion.
Civ. R. 12(B) provides in pertinent part:
“* * * When a motion to dismiss for failure to state a claim upon which relief can be granted presents matters outside the pleading and such matters are not excluded by the court, the motion shall be treated as a motion for summary judgment and disposed of as provided in Rule 56. * * *”
A court’s considering matters outside the pleadings to decide a motion to dismiss is permissible only if the court treats the motion as one for summary judgment. Thus, notwithstanding the entry of the complaint’s dismissal, it is proper that the court of appeals’ decision be reviewed as one of summary judgment.
This leads us to the principal issue of whether the court below properly granted summary judgment on the ground that relator had a plain and adequate remedy at law in the criminal discovery rule, Crim. R. 16(B)(1)(b).
Crim. R. 16(B)(1)(b) provides:
“Upon motion of the defendant the court shall order the prosecuting attorney to furnish defendant a copy of defendant’s prior criminal record, which is available to or within the possession, custody or control of the state.”
Clearly, the prosecution must give a defense attorney a copy of the criminal defendant’s prior criminal history. Crim. R. 16 is intended to provide the information sought, at no cost, expeditiously, and with the added protection to the defense of the sanctions available if the demand is not complied with.
Although relator agrees that he could obtain a copy of the desired records through a discovery request, he contends that pursuant to State, ex rel. Natl. Broadcasting Co., v. Cleveland (1988), 38 Ohio St. 3d 79, 526 N.E. 2d 786, and State, ex rel. Cincinnati Post, v. Schweikert (1988), 38 Ohio St. 3d 170, 527 N.E. 2d 1230, he is not obligated to pursue this alternative. Thus, he contends that, as a relator in a mandamus action seeking production of documents pursuant to R.C. 149.43, he is not required, as are relators in other mandamus actions, to show the absence of an adequate alternative to issuing the writ. He further argues that even if he were obligated, criminal discovery is not an adequate remedy at law.
• Appellant is correct in stating that in two recent cases this court has held that the respondents had a clear legal duty to release pertinent records and that the relators were entitled to them: State, ex rel. Natl. Broadcasting Co., supra; State, ex rel. Cincinnati Post, supra. See, also, State, ex rel. Outlet Communications, Inc., v. Lancaster Police Dept. (1988), 38 Ohio St. 3d 324, 528 N.E. 2d 175. However, the relator has misinterpreted the rationale in those two cases. In them, we made clear that in order for a writ of mandamus to issue a relator must show (1) that he has a clear legal right to the relief prayed for, (2) that respondent is under a clear legal duty to perform the *378requested act, and (3) that relator has no plain and adequate remedy in the ordinary course of law. State, ex rel. Natl. Broadcasting Co., supra, at 80, 526 N.E. 2d at 787; State, ex rel. Cincinnati Post, supra, at 172, 527 N.E. 2d at 1231. We expounded on the first two requirements but did not discuss the third. The reason for this omission was simply that a writ of mandamus was the only way for the relators in those cases to secure the records sought. Thus, the relators lacked an adequate alternative remedy at law.
R.C. 149.43(C), as amended, provides:
“If a person allegedly is aggrieved by the failure of a governmental unit to promptly prepare a public record and to make it available to him for inspection in accordance with division (B) of this section, or if a person who has requested a copy of a public record allegedly is aggrieved by the failure of a person responsible for it to make a copy available to him in accordance with division (B) of this section, the person allegedly aggrieved may commence a mandamus action to obtain a judgment that orders the governmental unit or the person responsible for the public record to comply with division (B) of this section and that awards reasonable attorney’s fees to the person that instituted the mandamus action. The mandamus action may be commenced in the court of common pleas of the county in which division (B) of this section allegedly was not complied with, in the supreme court pursuant to its original jurisdiction under Section 2 of Article IV, Ohio Constitution, or in the court of appeals for the appellate district in which division (B) of this section allegedly was not complied with pursuant to its original jurisdiction under Section 3 of Article IV, Ohio Constitution.”
We applied this statute in State, ex rel. Fostoria Daily Review Co., v. Fostoria Hosp. Assn. (1988), 40 Ohio St. 3d 10, 531 N.E. 2d 313 (‘Fostoria II”) and granted a writ of mandamus ordering the production of certain hospital documents. We noted with particularity that R.C. 149.43(C) had been amended with the specific intent to supersede the holding of an earlier related case, namely, State, ex rel. Fostoria Daily Review Co., v. Fostoria Hosp. Assn. (1987), 32 Ohio St. 3d 327, 512 N.E. 2d 1176 (‘Fostoria I”).
The adequate alternative remedy that prevented a writ of mandamus in Fostoria I was a civil action under R.C. 149.99. However, this statute was repealed, effective October 15, 1987, when R.C. 149.43(C) was amended. Thus, Fostoria II and R.C. 149.43(C) prevent only the action formerly available under R.C. 149.99 from being an adequate alternative remedy. Fostoria II, like Natl. Broadcasting Co., supra, and Cincinnati Post, supra, referred to the standard ordinarily applicable in mandamus actions. See, e.g., Fostoria II, at 11, 531 N.E. 2d at 314. Therefore, along with showing a duty to produce public records and his rights thereto, a relator bringing an R.C. 149.43 mandamus claim must also show that he has no other adequate remedy available.
Relator contends that a Crim. R. 16 discovery demand is not an adequate alternative because preparing it would be costly and would require his client’s identity to be revealed. However, while R.C. 149.43 is a general statute giving access to records within the possession of a specific public official, Crim. R. 16 would give a criminal defendant access to full criminal felony histories, not just those cases within the jurisdiction where the official serves. This rule of discovery imposes a duty on the state to supple*379ment the discovery with after-acquired information, while R.C. 149.43 does not. In reality, Crim. R. 16 provides a more cost-efficient means of obtaining the information than does R.C. 149.43. Relator’s arguments are not well-taken.
To require the clerk of courts to compile this data through a search of the files in his possession, in an effort to duplicate information available from a prosecutor’s office, would be inefficient and add nothing to protect the rights of an accused. Thus, Crim. R. 16 provides more than adequate relief to the relator in the present case. Because he does have a plain and adequate alternative, he cannot be granted a writ of mandamus ordering the clerk to produce such a computer printout, even if we were to hold that relator was otherwise entitled to it.
As to whether such a compilation exists as a “document” included within the definition of “records” in R.C. 149.011, Cincinnati Post, supra, suggests that a compilation of information must already exist in public records before access to it will be ordered. Id. at 173, 527 N.E. 2d at 1232. We hold that the clerk could not be required to create a new “document” by compiling material to facilitate review of the public records. Conversely, if the clerk’s computer were already programmed to produce the desired printout, the “document” would already exist for the purpose of an R.C. 149.43 request. Accordingly, only if the relator did not have an adequate alternative remedy at law available, and he had properly requested the printout, would he be entitled to a writ of mandamus ordering its disclosure.
Finally, the relator alleges that the denial of his request for a writ of mandamus violates Amendments VI and XIV to the United States Constitution in their requirements of speedy and public trials, and equal protection of the laws for all persons.
However, relator filed the present action in his own behalf. Thus, even if a criminal defendant had been denied a speedy trial for some reason, relator would have no standing to assert that denial here. Furthermore, this court has never held that the Equal Protection Clause prohibits treating a relator who has an adequate remedy at law differently from one who does not. Since this distinction is not an arbitrary or irrational classification, we find no .denial of equal protection.
In conclusion, since relator has failed to establish that he lacked an adequate alternative remedy at law, the court of appeals properly found that the clerk was entitled to summary judgment. Therefore, the judgment of the court of appeals is affirmed.
Judgment affirmed.
Moyer, C.J., Sweeney, H. Brown and Resnick, JJ., concur. Douglas and Wright, JJ., dissent.