
778 P.2d 503 (1989)
98 Or.App. 75
Gilbert L. LANE, Appellant,
v.
Manfred MAASS, Superintendent, Oregon State Penitentiary, Respondent.
88 C 10808; CA A50272.
Court of Appeals of Oregon.
Argued and Submitted April 10, 1989.
Decided August 30, 1989.
Jay Edwards, Salem, argued the cause and filed the brief for appellant.
Vera Langer, Asst. Atty. Gen., Salem, argued the cause for respondent. With her on the brief were Dave Frohnmayer, Atty. Gen., and Virginia L. Linder, Sol. Gen., Salem.
Before RICHARDSON, P.J., and NEWMAN and DEITS, JJ.
RICHARDSON, Presiding Judge.
Plaintiff appeals the dismissal of his petition for a writ of habeas corpus for lack of subject matter jurisdiction. ORCP 21 A(1). He contends that the facts support the issuance of the writ. We conclude that dismissal under ORCP 21 A(1) was procedurally improper and, therefore, reverse and remand.
In his petition, plaintiff alleged that he was being unlawfully imprisoned and restrained, because he had been forced to provide a urine sample for drug analysis. He explained in his petition that, when he was unable immediately to provide a sample, he was threatened with a loss of privileges. After approximately 100 minutes of effort, plaintiff asked that the sample be obtained by a catheter, but his request was refused. He eventually provided the sample, but, he alleged, the effort caused dizziness and a two-hour headache.
A writ was issued. Defendant filed a return stating only that plaintiff was lawfully imprisoned pursuant to a judgment and sentence. Plaintiff then filed a replication, and defendant moved to dismiss the petition "on the ground that the court lacks jurisdiction of the subject of the action." ORCP 21 A(1). The court granted the motion, finding that

*504 "plaintiff's allegations in the present case do not state a claim for habeas corpus relief, and finding further that the allegations do not comprise a claim requiring immediate judicial examination, and that there are adequate alternative remedies available to plaintiff in the form of preliminary injunction and tort claims which are sufficiently timely to afford plaintiff relief, and that based on the foregoing, this court lacks habeas corpus jurisdiction over the subject matter of plaintiff's action, and the Replication fails to allege ultimate facts sufficient to constitute a claim for habeas corpus relief."
The court entered a judgment dismissing plaintiff's replication and the case.[1]
Plaintiff contends only that the court erred in granting the motion to dismiss, because his allegations do constitute a claim for habeas corpus relief. In Bedell v. Schiedler, 307 Or. 562, 770 P.2d 909 (1989), the Supreme Court reviewed the dismissal of a habeas corpus petition under ORCP 21 A(1) and concluded that
"any motion practice other than an ORS 34.680 motion to strike is inappropriate in habeas corpus actions. Any additional motion practice would only lengthen and complicate actions intended to provide an expeditious and summary resolution of the issues presented." 307 Or. at 566, 770 P.2d 909.
The dismissal on the basis of ORCP 21 A(1) was, therefore, procedurally inappropriate. In the absence of a motion under ORS 34.680, the court should have proceeded to hear the evidence and decide the case. ORS 34.670; Bedell v. Schiedler, supra, 307 Or. at 566, 770 P.2d 909.
Reversed and remanded.
NOTES
[1]  After the court issued the writ, plaintiff's original petition was no longer a pleading in the matter and, therefore, defendant's motion should not have been considered. Gage v. Maass, 306 Or. 196, 759 P.2d 1049 (1988). The court apparently considered the challenge as directed to the replication. In any event, if the court erred in reviewing the challenge to the "petition," such error was harmless. Gage v. Maass, supra, 306 Or. at 203, 759 P.2d 1049.
