
455 S.E.2d 901 (1995)
118 N.C. App. 564
Thomas A. RITTER, Petitioner,
v.
DEPARTMENT OF HUMAN RESOURCES, Respondent.
No. 9410SC615.
Court of Appeals of North Carolina.
April 18, 1995.
*902 Allen & Pinnix by M. Jackson Nichols, Raleigh, for petitioner-appellant.
Attorney General Michael F. Easley by Asst. Atty. Gen. Robert M. Curran, for respondent-appellee.
EAGLES, Judge.
Petitioner contends that the trial erred in affirming the State Personnel Commission's (hereinafter Commission) decision upholding his dismissal. After careful review of the record and briefs, we affirm.
We note initially that respondent has cross-assigned as error the administrative law judge's (hereinafter ALJ) denial of its motion to dismiss for lack of subject matter jurisdiction. Respondent contends that petitioner did not file a petition for a contested case hearing within thirty days of receiving respondent's letter confirming petitioner's dismissal. G.S. 126-38. Although the petition was not filed with the Office of Administrative Hearings within thirty days after petitioner received notice of respondent's decision, we exercise our discretion pursuant to Rule 2 of the North Carolina Rules of Appellate Procedure to address the merits of petitioner's appeal.


*903 I.
Petitioner first contends that the trial court erred in denying his request to remand the case to the Office of Administrative Hearings to take additional evidence regarding petitioner's alcohol assessment, treatment and recovery. We disagree.
G.S. 150B-49 provides:
An aggrieved person who files a petition in the superior court may apply to the court to present additional evidence. If the court is satisfied that the evidence is material to the issues, is not merely cumulative, and could not reasonably have been presented at the administrative hearing, the court may remand the case so that additional evidence can be taken.
Petitioner argues that he successfully completed an alcohol recovery program after the hearing before the Commission. Petitioner contends that his earlier misbehavior was due to alcohol and that the evidence of his alcoholism and treatment were material issues to the case and could not have been presented at the hearing.
Petitioner was discharged for unacceptable personal conduct. His dismissal stemmed from his requesting Sheriff McQueen to write a letter discrediting one of petitioner's subordinate employees and his abusive behavior toward Sheriff McQueen when he refused to write such a letter. Petitioner's alcohol assessment and subsequent treatment is not material to the issues involved. Petitioner's alcoholism does not afford petitioner a defense for his termination for just cause. Even if petitioner's alcohol assessment and treatment were issues material to petitioner's dismissal, the trial court's decision here to deny petitioner's motion to remand for additional evidence can be reversed only for abuse of discretion. G.S. 150B-49. This assignment of error is overruled.

II.
Petitioner further contends that the trial court erred in affirming his dismissal because the Commission did not state specific reasons for rejecting the recommended decision of the ALJ. We disagree.
If an agency does not adopt the ALJ's recommended decision as its final decision, the agency must state the specific reasons why it did not adopt the ALJ's recommended decision. G.S. 150B-36(b). Upon judicial review, a reviewing court must determine whether the agency's decision adequately states specific reasons why it did not adopt the ALJ's decision. G.S. 150B-51(a). In Ford v. N.C. Dep't. of Environment, Health, and Natural Resources, 107 N.C.App. 192, 419 S.E.2d 204 (1992), this court affirmed a final agency decision where the respondent agency selectively adopted and rejected the ALJ's recommended findings of fact. The respondent agency also rejected the ALJ's conclusions of law based upon its own findings of fact. This court held that the respondent agency's order sufficiently satisfied the spirit of G.S. 150B-36 and G.S. 150B-51. Examining this record in light of Ford, we conclude that the Commission's order states with sufficient specificity the reasons why it did not adopt the ALJ's recommended decision.
Petitioner also contends here that the Commission erroneously rejected several of the ALJ's findings of fact as "irrelevant" or "not supported by substantial, credible evidence." In reviewing a final agency decision, the trial court must apply the "whole record" test, which requires an examination of all the evidence to determine whether the agency's decision is supported by substantial evidence. Rector v. N.C. Sheriffs' Educ. and Training Standards Com'n., 103 N.C.App. 527, 532, 406 S.E.2d 613, 616 (1991); G.S. 150B-51(b)(5). The trial court is not permitted to substitute its judgment for the agency's judgment when there are two reasonably conflicting views. Id. Respondent's decision to adopt its own findings of fact and to reject many of the ALJ's recommended findings of fact is supported by the whole record. This assignment of error fails.

III.
Finally, petitioner contends that the Commission's decision was arbitrary and capricious. Our review of the record shows that the Commission's decision dismissing petitioner is supported by the whole record *904 and was not arbitrary and capricious. This assignment of error also fails.
In sum, the trial court did not err in affirming petitioner's dismissal for just cause.
Affirmed.
WALKER and McGEE, JJ., concur.
