
322 N.W.2d 394 (1982)
212 Neb. 181
STATE ex rel. Rolland JAKES, Jr., Appellant,
v.
NEBRASKA BOARD OF PAROLE et al., Appellees.
No. 44389.
Supreme Court of Nebraska.
July 16, 1982.
*395 Dennis R. Keefe, Lancaster County Public Defender, and Richard L. Goos, Lincoln, for appellant.
Paul L. Douglas, Atty. Gen., and Lynne Fritz, Lincoln, for appellees.
Heard before KRIVOSHA, C. J., and BOSLAUGH, McCOWN, CLINTON, WHITE, HASTINGS and CAPORALE, JJ.
HASTINGS, Justice.
The appellant, Rolland Jakes, Jr., filed this action in the Lancaster County District Court seeking the issuance of a writ of mandamus to compel the appellees to give him credit against his sentence for time served following the revocation of his parole on January 3, 1977. The District Court denied the request for the writ and dismissed the appellant's petition, finding that a writ of mandamus was not the proper remedy in this instance. The appellant has assigned numerous errors on this appeal which can be summarized generally into a claim that the trial court erred in failing to find that the appellant had a legal right to the relief requested; in finding that Neb. Rev.Stat. § 83-1,123 (Reissue 1981) did not impose a clear, unequivocal, and mandatory duty on the appellees to grant the soughtafter credits against his sentence; and that it was error not to issue the writ of mandamus and to dismiss the petition. We affirm.
The appellant was initially incarcerated in the Nebraska Penal Complex on January 26, 1971, to a term of not less than 5 nor more than 10 years on a conviction for escape. He was released on parole to Minnesota on or about November 21, 1974, but was arrested by Minnesota authorities on December 11, 1974, and charged with aggravated assault. Appellant pled guilty to this charge and, pursuant to plea negotiations, was sentenced on March 26, 1975, to a term not to exceed 7½ years, said sentence to run "concurrent" with any time to be served by appellant in Nebraska. On July 27, 1976, a probable cause hearing relating to a possible violation of appellant's Nebraska parole was conducted for Nebraska by a Minnesota hearing officer and resulted in a finding of probable cause that the appellant had indeed violated his Nebraska parole. Appellant was returned to Nebraska on December 7, 1976, pursuant to the provisions of the Interstate Corrections Compact, Neb. Rev.Stat. § 29-3401 (Reissue 1979).
Upon appellant's return to Nebraska the appellee Board of Parole conducted an initial hearing on the revocation of appellant's parole on December 21, 1976, which was continued following the appellant's request that his attorney be present. A second hearing was held on January 3, 1977, and resulted in the revocation of appellant's Nebraska parole. It would appear from the record that at all times after December 7, 1976, appellant remained incarcerated in the Nebraska Penal Complex. As a matter of fact, the records of the Board of Parole, which were offered and received into evidence, indicate that the Board reviewed appellant's *396 record on three different occasions between January and March 1978, with the final review resulting in a deferral of appellant's case until March 1979. In May 1979 he was paroled by Nebraska, although he violated that parole soon thereafter and was again incarcerated. In the meantime, on April 11, 1978, the Minnesota authorities paroled the appellant on the sentence received on the aggravated assault charge. However, appellant remained in custody in the Nebraska Penal Complex to serve the time remaining on his original Nebraska sentence for the escape conviction, except for the parole in May of 1979.
The request which forms the basis for this mandamus action is that of the appellant that the Board of Parole be compelled to give him credit against the time remaining on his original Nebraska sentence for the period between January 3, 1977, the date on which his Nebraska parole was revoked, and April 11, 1978, when the appellant was paroled by the Minnesota authorities. Both parties agree that the appellant was physically incarcerated in the Nebraska Penal Complex during this period. The dispute arises from the differing interpretations each party has given to the authority and duty of the Board following the revocation of a parolee's parole.
The emphasis the parties have placed upon the Board of Parole's duty following the revocation of parole is not misplaced in light of the well-established prerequisites for the issuance of a writ of mandamus. A writ of mandamus is a proper remedy to compel an official to act only when the duty to act is imposed upon the official by law, when the duty continues to exist at the time the writ is applied for, and when the duty is clearly expressed in the law. Singleton v. Kimball County Board of Commissioners, 203 Neb. 429, 279 N.W.2d 112 (1979); State ex rel. Goossen v. Board of Supervisors, 198 Neb. 9, 251 N.W.2d 655 (1977).
The appellant asserts in this action that the Board of Parole had a clear duty imposed upon it by § 83-1,123 to "recommit" him for the remainder of his Nebraska prison term once they revoked his parole on January 3, 1977. The terms of this section provide that "(1) A parolee whose parole is revoked shall: (a) Be recommitted for the remainder of his maximum prison term, deducting the period served on parole prior to the violation ...." We must also note, however, that actual physical custody of the former parolee is apparently an essential element to the commencement of the running of his sentence upon revocation of parole. This conclusion arises from the fact that the former parolee is considered "an escaped prisoner until apprehended and returned to the Department of Correctional Services" and, furthermore, "until the date of his arrest for the custody of the Board of Parole" no time after a delinquency of parole is declared shall be counted as a portion of time served. § 83-1,123(1)(b) and (2). The essence of actual physical custody is made all the more apparent by the fact that the Board of Parole is continuously in the "legal custody and control" of all persons discharged on parole. (Emphasis supplied.) Neb.Rev.Stat. § 83-1,121 (Reissue 1981). Consequently, although the Board of Parole may have "legal custody" of a parolee, it is readily apparent that actual physical custody, effectuated by an "arrest" or "apprehension" of the parole violator, is necessary before "recommitment" is possible.
The peculiar circumstances surrounding this set of facts makes the foregoing analysis particularly important. As noted, the appellant's presence in Nebraska was accomplished under the Interstate Corrections Compact. The provisions of the compact provide that inmates confined under the terms of the compact "shall at all times be subject to the jurisdiction of the sending State [Minnesota] and may at any time be removed therefrom for transfer to a prison or other institution within the sending State ...." § 29-3401, art. IV(c). The appellee relies on this provision in support of its contention that it could not recommit the appellant since it did not have actual custody or control of appellant until the latter's parole by Minnesota on April 11, 1978. In doing so, however, appellee ignores another provision of the compact which limits the sending state's power of removal in the following manner: "[I]f at the time the sending State [Minnesota] *397 seeks to remove an inmate from an institution in the receiving State [Nebraska] there is pending against the inmate within such State any criminal charge or if the inmate is formally accused of having committed within such State a criminal offense, the inmate shall not be returned without the consent of the receiving State until discharged from prosecution or other form of proceeding, imprisonment or detention for such offense." § 29-3401, art. V(a). Under such a provision the State of Nebraska may very well have been able to retain possession of the appellant for the duration of his Nebraska sentence had Minnesota sought to remove him from this state.
In any event, it is apparent from the foregoing discussion that the appellant's exact status and the appellee's exact duty in relation thereto are far from clear. As noted in our discussion of the prerequisites for a writ of mandamus, an official's duty must be clearly expressed in the law before a writ is properly issued. While the Board of Parole may have a clear duty to recommit a parolee to serve the remainder of his sentence following the revocation of his parole, we do not even reach that point under the present set of facts. Whether or not the board has a clear duty to recommit the appellant depends upon whether the appellant has been arrested for the "custody of the Board of Parole" and "apprehended and returned to the Department of Correctional Services." § 83-1,123. Until the appellant's status is clearly established in that respect under the Interstate Corrections Compact and the laws governing the Board of Parole, the Board does not have a clear duty to act under the law, and the appellant was not entitled to a writ of mandamus.
The foregoing conclusion is all the more appropriate in light of the general rule that mandamus is an extraordinary remedy which is not awarded as a matter of right and will not issue where there is another plain and adequate remedy available. State ex rel. Newbold v. County of Buffalo, 202 Neb. 813, 277 N.W.2d 246 (1979). The discussion above makes it readily apparent that the appellant is one "whose rights, status or other legal relations are affected by a statute." Neb.Rev.Stat. § 25-21,150 (Reissue 1979). As such, appellant is entitled to have his rights or status under the law determined in an action seeking a declaratory judgment pursuant to the Uniform Declaratory Judgments Act. Neb. Rev.Stat. §§ 25-21,149 to 25-21,164 (Reissue 1979). Furthermore, as noted by the trial court, appellant may, at the appropriate time, file a petition in habeas corpus to contest the lawfulness of his continued imprisonment.
We have held in the past that "where a specific duty is provided by statute, mandamus may be invoked to enforce it if denied; and the party entitled to such relief will not be forced to pursue his remedy by circuitous and dilatory action at law." State ex rel. Simpson v. Vondrasek, 203 Neb. 693, 701-02, 279 N.W.2d 860, 866 (1979). However, in this instance there is no such "specific duty" which has not been performed by the appellee Board of Parole. Until the appellant's status under the law is determined, a task more appropriately achieved in an action for a declaratory judgment, no such clear or specific duty shall be present. The judgment of the trial court is hereby affirmed.
AFFIRMED.
