At issue in this case is whether, pursuant to G. L. c. 32, § 15 (4), John P. Bulger’s convictions of two counts of perjury and two counts of obstruction of justice in Federal District Court involved “violation[s] of the laws applicable to his office or position” as clerk-magistrate of the Boston Juvenile Court such that he forfeited his entitlement to a retirement allowance as a member of the State employees’ retirement system. For the reasons that follow, we conclude that Bulger did violate the laws applicable to his office and that, consequently, forfeiture of his pension was statutorily required.
Bulger began his employment with the Commonwealth in 1964, when he was hired by the Metropolitan District *170Commission. In June, 1982, Bulger was appointed to serve as clerk-magistrate of the Boston Juvenile Court.2 When he was sworn into office, Bulger pledged to “bear true faith and allegiance to the Commonwealth of Massachusetts” and to “support the constitution thereof.” Part H, c. 6, art. 1, of the Constitution of the Commonwealth, as amended by art. 6 of the Amendments. He further solemnly swore and affirmed that he would “faithfully and impartially discharge and perform all the duties incumbent upon [him] as [the Clerk-Magistrate of the Boston Juvenile Court]: according to the best of [his] abilities and understanding, agreeably, to the rules and regulations of the constitution, and the laws of [the] Commonwealth.” Id. Last, Bulger solemnly swore that he would “support the Constitution of the United States.” See art. VI, third par., of the United States Constitution. This appointment lasted for nearly nineteen years.
Effective April 27, 2001, Bulger was granted a superannuation retirement from his position as clerk-magistrate. See G. L. c. 32, § 5. He was credited with thirty-two years and nine months of service with the State, and the Commonwealth began to pay Bulger a monthly pension of $5,326.16.3 Continued payment of Bulger’s retirement allowance during his lifetime was subject to, among other things, the provisions of G. L. c. 32, § 15, which pertain to dereliction of duty by a member of the contributory retirement system for public employees (member). See G. L. c. 32, § 12 (2). General Laws c. 32, § 15 (4), in particular, provides, in relevant part, as follows:
“In no event shall any member after final conviction of a criminal offense involving violation of the laws applicable to his office or position, be entitled to receive a retire*171ment allowance under the provisions of [§§ 1-28], inclusive, nor shall any beneficiary be entitled to receive any benefits under such provisions on account of such member” (emphasis added).
On November 8, 2001, Bulger was indicted in the United States District Court for the District of Massachusetts on two counts of pequry, in violation of 18 U.S.C. § 1623 (2000), and two counts of obstruction of justice, in violation of 18 U.S.C. § 1503 (2000). A grand jury had been conducting an investigation into alleged money laundering, racketeering, and other criminal offenses committed by, among others, Bulger’s brother, James Bulger. It was material to this investigation that the grand jury determine “the nature, location, source, form, and ownership of any properties, accounts, safe deposit boxes, cash, and other assets possessed, controlled, transferred and transacted” by James Bulger. The indictment alleged that, on November 26, 1996, Bulger falsely testified, under oath, that he had no knowledge of any safe deposit box belonging to or controlled by James Bulger. According to the indictment, the purpose and effect of such testimony was to obstruct and impede the grand jury investigation.
A grand jury also had been conducting an investigation into persons involved in the commission of criminal offenses related to harboring and concealing James Bulger, who had been a fugitive from Federal criminal charges in Massachusetts since January, 1995. The November 8, 2001, indictment alleged that, on January 22, 1998, Bulger falsely testified, under oath, that, since January, 1995, he had received no direct or indirect communications from James Bulger, and that he was unaware of others who had received such communications. According to the indictment, the purpose and effect of this testimony was, once again, to obstruct and impede the grand jury investigation.
On April 10, 2003, Bulger pleaded guilty to the two counts of perjury and two counts of obstruction of justice set forth in the November 8, 2001, indictment. He was sentenced to serve a prison term of six months and three years of supervised release (with the first six months of the latter spent in home confinement), and to pay a fine of $3,000 and a mandatory assessment of $400.
*172The State Board of Retirement (board) notified Bulger that it was commencing a proceeding to determine whether it should take any action in connection with his retirement allowance. Additionally, the board informed Bulger that it intended to withhold the distribution of further pension payments to Bulger until final disposition of the matter. In response to Bulger’s request for immediate resumption of his pension payments, the board voted at its August 28, 2003, meeting to deny his request. Bulger filed a petition in the South Boston Division of the Boston Municipal Court, see G. L. c. 218, § 1, seeking judicial review of the board’s determination pursuant to G. L. c. 32, § 16 (3) (a).
On September 22, 2003, following a hearing at which Bulger was represented by counsel, a hearing officer recommended that, in light of Bulger’s convictions, the board rescind his retirement allowance and commence collection efforts to recover the $69,874.28 previously paid by the board to Bulger as the part of his retirement allowance that exceeded the contributions he had made to the retirement system. The board adopted the hearing officer’s recommendations at its meeting on September 25, 2003. Bulger then filed another petition in the Boston Municipal Court seeking judicial review of the board’s final determination. In accordance with G. L. c. 30A, § 14, the board filed a motion for summary judgment, limited to the board’s administrative action against Bulger pursuant to G. L. c. 32, § 15 (4).
On September 29, 2004, a judge in the Boston Municipal Court denied the board’s motion for summary judgment, reversed the board’s determination permanently to rescind Bulger’s retirement allowance, and ordered the board to reinstate Bulger’s pension, retroactive to April 11, 2003. The judge concluded that while Bulger’s convictions of perjury and obstruction of justice were serious, they did not constitute “violation[s] of the laws applicable to his office or position,” within the purview of G. L. c. 32, § 15 (4), where “they were unrelated to Bulger’s position as a Clerk Magistrate and where the facts and circumstances that gave rise to the convictions did not involve the administration of his duties and responsibilities as an appointed government official.” The board filed a complaint seeking review in the nature of certiorari, pursuant to *173G. L. c. 249, § 4, in the Supreme Judicial Court for Suffolk County, asserting that the judge had misinterpreted G. L. c. 32, § 15 (4), and that Bulger had violated the laws applicable to his position as clerk-magistrate. A single justice reserved and reported the matter to the full court.4
General Laws c. 249, § 4, provides for limited judicial review in the nature of certiorari to correct errors of law in administrative proceedings where judicial review is otherwise unavailable. See Sheriff of Plymouth County v. Plymouth County Personnel Bd., 440 Mass. 708, 710 (2004); Carney v. Springfield, 403 Mass. 604, 605 (1988). Certiorari allows a court to “correct only a substantial error of law, evidenced by the record, which adversely affects a material right of the plaintiff. ... In its review, the court may rectify only those errors of law which have resulted in manifest injustice to the plaintiff or which have adversely affected the real interests of the general public” (quotations and citations omitted). Massachusetts Bay Transp. Auth. v. Auditor of the Commonwealth, 430 Mass. 783, 790 (2000), quoting Carney v. Springfield, supra.
The thrust of the board’s argument is that Bulger must forfeit his pension, pursuant to G. L. c. 32, § 15 (4), because his convictions of perjury and obstruction of justice constituted “violation[s] of the laws applicable to his office,” namely the Code of Professional Responsibility for Clerks of the Courts (the code), S.J.C. Rule 3:12, as amended, 427 Mass. 1322 (1998). The board points out that the position of clerk-magistrate is one of public trust and that Bulger, when he was appointed to that position, took an oath of office to uphold the Federal and *174State Constitutions and the laws of this Commonwealth. The board argues that the crimes committed by Bulger did not constitute mere personal transgressions wholly unrelated to the office of clerk-magistrate but, rather, were crimes that undermined the very essence of a clerk-magistrate’s responsibility to facilitate the administration of justice. Because, in the board’s opinion, there was a direct link between Bulger’s convictions and the laws applicable to his office, Bulger forfeited his entitlement to his retirement allowance under G. L. c. 32, § 15 (4). We agree.
Our analysis of G. L. c. 32, § 15 (4), is guided by the familiar principle that “a statute must be interpreted according to the intent of the Legislature ascertained from all its words construed by the ordinary and approved usage of the language, considered in connection with the cause of its enactment, the mischief or imperfection to be remedied and the main object to be accomplished, to the end that the purpose of its framers may be effectuated.” Hanlon v. Rollins, 286 Mass. 444, 447 (1934). See Sullivan v. Brookline, 435 Mass. 353, 360 (2001). Courts must ascertain the intent of a statute from all its parts and from the subject matter to which it relates, and must interpret the statute so as to render the legislation effective, consonant with sound reason and common sense. See Champigny v. Commonwealth, 422 Mass. 249, 251 (1996); Pentucket Manor Chronic Hosp., Inc. v. Rate Setting Comm’n, 394 Mass. 233, 240 (1985); Tilton v. Haverhill, 311 Mass. 572, 577-578 (1942).
Subsection (4) of G. L. c. 32, § 15, was inserted by St. 1987, c. 697, § 47, and, pursuant to § 135, was made applicable only to criminal offenses committed on or after its effective date, January 12, 1988.5 For purposes of statutory construction, G. L. c. 32, § 15 (4), is considered to be penal and, therefore, its *175language must be construed narrowly, not stretched to accomplish an unexpressed result. See Gaffney v. Contributory Retirement Appeal Bd., 423 Mass. 1, 3 n.3 (1996); Collatos v. Boston Retirement Bd., 396 Mass. 684, 686-687 (1986). Contrast MacLean v. State Bd. of Retirement, 432 Mass. 339, 351 & n.15 (2000) (concluding that revocation of pension benefits under § 15 [4] not “criminal punishment” for purposes of double jeopardy); Doherty v. Retirement Bd. of Medford, 425 Mass. 130, 136-137 (1997) (concluding that use of term “forfeit” in § 15 [1] did not render statute “so punitive as to overcome its restitutionary purpose”). A member who becomes subject to the mandates of § 15 (4) forfeits entitlement to a retirement allowance, but the member “shall receive, unless otherwise prohibited by law, a return of his accumulated total deductions; provided, however, that the rate of regular interest for the purpose of calculating accumulated total deductions shall be zero.” G. L. c. 32, § 15 (4).
The scope of G. L. c. 32, § 15 (4), was enunciated in Gaffney v. Contributory Retirement Appeal Bd., supra at 4-5, where we stated that “[t]he substantive touchstone intended by the General Court is criminal activity connected with the office or position. . . . [T]he General Court did not intend pension forfeiture to follow as a sequelae of any and all criminal convictions. Only those violations related to the member’s official capacity were targeted. Looking to the facts of each case for a direct link between the criminal offense and the member’s office or position best effectuates the legislative intent of § 15 (4).”
With these general principles in mind, we consider what laws are applicable to the office or position of clerk-magistrate and, then, whether Bulger violated those laws. We begin with an overview of the office of clerk-magistrate.
The position of clerk-magistrate is one created and defined by statute. See G. L. c. 218, §§ 8, 33, 35A, 58; G. L. c. 221, §§ 62B, 62C. See also Commonwealth v. Clerk-Magistrate of the W. Roxbury Div. of the Dist. Court Dep’t, 439 Mass. 352, 354 (2003). “A clerk of a court is ‘a public officer clothed with official functions of a highly important nature.’ ” Massachusetts Bar Ass’n v. Cronin, 351 Mass. 321, 325-326 (1966), quoting *176O’Connell v. Retirement Bd. of Boston, 254 Mass. 404, 406 (1926). After being sworn into office, see G. L. c. 218, § 12, a clerk “shall have responsibility for the internal administration of his office, including personnel, staff services and record keeping.” G. L. c. 218, § 8. See G. L. c. 218, §§ 12, 57A. Pursuant to G. L. c. 218, § 33, a clerk may, among other duties, “receive complaints, administer to complainants the oath required thereto, and issue warrants, search warrants and summonses.” See G. L. c. 218, § 59. A clerk also administers oaths to witnesses. See Massachusetts Bar Ass’n v. Cronin, supra at 326. Further, the authority of a clerk includes “the power to grant continuances; to hear and rule on uncontested nonevidentiary motions; to hold pretrial conferences; to mediate, hear and decide small claims; to hold preliminary hearings to determine whether there is probable cause to believe that a probationer has violated the terms of his probation; to conduct show cause hearings on certain applications for criminal complaints; to pass on the appropriateness of applications for warrants; and to set bail in certain circumstances. See G. L. c. 221, § 62C; G. L. c. 218, §§ 21, 22, 33, 35A; G. L. c. 276, §§ 57, 58.” First Justice of the Bristol Div. of the Juvenile Court Dep’t v. Clerk-Magistrate of the Bristol Div. of the Juvenile Court Dep’t, 438 Mass. 387, 398 (2003).
“[T]he responsibilities of a clerk-magistrate, while largely ministerial, are inextricably related and essential to the effective functioning of the courts in this Commonwealth. ” Commonwealth v. Clerk-Magistrate of the W. Roxbury Div. of the Dist. Court Dep’t, supra at 359. See First Justice of the Bristol Div. of the Juvenile Court Dep’t v. Clerk-Magistrate of the Bristol Div. of the Juvenile Court Dep’t, supra at 398-399. The function of every court “is to ensure the integrity of the judicial system, which must not only be beyond suspicion but must appear to be so. The duties of a clerk of a court are performed, for the most part, under public scrutiny. He is a conspicuous figure in the court room. He is seated prominently near the judge, where he is in frequent consultation with him as well as with various lawyers. He administers oaths to witnesses. . . . [I]t would be incongruous to hold out as clerk one who has not conformed to the standards essential to every court.” Massachusetts Bar Ass’n v. Cronin, supra at 326.
*177The high standards to which clerks are held are plainly enunciated in the code, which was adopted on February 9, 1990, as S.J.C. Rule 3:12, as amended, 427 Mass. 1322 (1998).6 See Opinion of the Justices, 375 Mass. 795, 813 (1978) (Supreme Judicial Court has “the authority by rule to establish standards of conduct for judicial employees and officials”). “Rules of court have the force of law . . . .” Empire Apartments, Inc. v. Gray, 353 Mass. 333, 337 (1967). See Berkwitz, petitioner, 323 Mass. 41, 47 (1948) (rules of court “have the force of law and are just as binding on the court and the parties as would be a statute”). “[Rjules of court are designed primarily to accomplish the ends of justice, protect rights, serve the convenience of litigants and implement the substantive law.” Commonwealth v. Brown, 395 Mass. 604, 606 (1985), quoting Albermont Petroleum, Ltd. v. Cunningham, 186 Cal. App. 2d 84, 91 (1960). In accordance with these purposes, the code imposes on a clerk-magistrate a significant responsibility for upholding the integrity of the judicial system, for promoting public confidence in the administration of justice, for honoring the public trust placed in such office, for avoiding the appearance of any impropriety in his activities, and for fulfilling the mandates of the oath of office.
The “laws” applicable to the office or position of clerk-magistrate include the code because it establishes the very *178standards governing the norms of conduct and practice associated with such office. That said, the language of the code enunciating the high standards to which clerks are held is broad, whereas the language of G. L. c. 32, § 15 (4), is narrower, no doubt due to the severity of pension forfeiture as a sanction for dereliction of duty by a member. Accordingly, for our purposes, the general mandates of the code must be viewed in the context of the more specific language of § 15 (4). Here, the question becomes whether Bulger violated the laws applicable to his office or position when he was convicted of perjury and obstruction of justice in an arguably personal matter such that he was required to forfeit his retirement allowance pursuant to § 15 (4).
The board asserts that, in order to make this determination, we should consider whether Bulger’s criminal convictions, had they occurred when he still was employed as a clerk-magistrate, would have resulted in his removal from office.7 We conclude that such an analysis is too broad, and it fails to recognize that the standards for a member’s removal from office and for a member’s forfeiture of a retirement allowance are different.
Statutory authority for removal of a clerk-magistrate is set forth in G. L. c. 211, § 4. “A majority of the Justices, upon a summary hearing or otherwise, may remove a clerk . . . upon a complaint ‘if sufficient cause is shown therefor and it appears that the public good so requires.’ ” Matter of Dugan, 416 Mass. 461, 463 (1993), quoting G. L. c. 211, § 4 (removal of clerk-magistrate for pervasive abuses of power in office). See Massachusetts Bar Ass’n v. Cronin, 351 Mass. 321, 324-326 (1966) (removing District Court clerk from office for committing perjury before grand jury in bribery matter unrelated to his duties as clerk). See also Attorney Gen. v. Flynn, 331 Mass. 413, 414-415, 429-430 (1954) (removing district attorney from office for misconduct as trustee of charitable trust, unrelated to his official duties, where evidence disclosed “a man lacking in the sound moral perceptions and in the steadfast moral character necessary for the exercise of the enormous powers of the office *179of district attorney . . . and for the creation and retention of public confidence in the administration of that great office”); Attorney Gen. v. Tufts, 239 Mass. 458, 498 (1921) (removing district attorney from office where “[pjremeditated deception accompanied by the deliberate telling of lies” demonstrated bad judgment, untrustworthiness, and “a lamentable want of appreciation of moral values”). Cf. G. L. c. 279, § 30 (convict holding office under Constitution or laws of Commonwealth at time of sentence to State prison or Federal penitentiary must vacate office).
As enunciated by G. L. c. 211, § 4, and by our case law, the standard for removing a clerk-magistrate from office, where required by the “public good,” is broad. In contrast, the standard for pension forfeiture based on dereliction of duty is more narrow and specific. A clerk-magistrate’s pension is forfeited for misappropriation of governmental funds or property, G. L. c. 32, § 15 (1) and (3), after a final conviction of certain offenses set forth in G. L. c. 32, § 15 (3A), or after a final conviction of a criminal offense involving “violation of the laws applicable to his office or position,” G. L. c. 32, § 15 (4). See Gaffney v. Contributory Retirement Appeal Bd., 423 Mass. 1, 3 (1996). Depending on the misconduct at issue, there may be instances when removal of a clerk-magistrate from office is mandated by G. L. c. 211, § 4, because it serves the public good, but pension benefits are not concomitantly terminated because the misconduct at issue does not fall within the purview of G. L. c. 32, § 15. For example, a member may be convicted of a criminal offense that does not involve any violation of the laws applicable to his office or position. In those circumstances, according to G. L. c. 32, § 15 (4), the member does not forfeit his entitlement to a retirement allowance. This is not one of those cases.
At the heart of a clerk-magistrate’s role is the unwavering obligation to tell the truth, to ensure that others do the same through the giving of oaths to complainants, and to promote the administration of justice. When Bulger committed the crimes of pequry and obstruction of justice, he violated the fundamental tenets of the code and of his oath of office, notwithstanding his contention that such misconduct occurred in the context of what was arguably a personal matter. We recognized in Gaffney v. *180Contributory Retirement Appeal Bd., supra at 3-4, that § 15 (4) was enacted in response to this court’s decision in Collatos v. Boston Retirement Bd., 396 Mass. 684 (1986), and that the Legislature intended “to avoid having the precise form of the criminal enforcement action make a difference with respect to the pension forfeiture issue.” We concluded in the Gaffney case that § 15 (4) was not limited to violations of “highly specialized crimes addressing official actions” or even criminal conduct committed “in the course of [official] duties,” but encompassed “criminal activity connected with the office or position.” Gaffney v. Contributory Retirement Appeal Bd., supra at 4. The nature of Bulger’s particular crimes cannot be separated from the nature of his particular office when what is at stake is the integrity of our judicial system. We conclude that Bulger’s convictions of perjury and obstruction of justice involved “violation[s] of the laws applicable to his office or position,” pursuant to G. L. c. 32, § 15 (4), and mandated the forfeiture of his retirement allowance.
This case is to be remanded to the county court for entry of a judgment reversing the judgment of the Boston Municipal Court.
So ordered.
Since 1978, clerks of Juvenile Court “shall hereafter also have the title of magistrate for their particular department, or division as the case may be, of the trial court.” G. L. c. 221, § 62B. “Magistrates herein provided shall continue to have and exercise all the powers, duties and responsibilities of clerks and registers and shall also have those provided for in [§ 62C].” Id.
Bulger requested that his pension be paid in accordance with “Option A,” as set forth in G. L. c. 32, § 12 (2), whereby a member receives a Ml retirement allowance consisting of a regular life annuity, a pension, and an additional life annuity. All benefits cease on the member’s death, except as otherwise provided by the option elected. See G. L. c. 32, § 12 (2).
Bulger’s petition for judicial review of the board’s final determination raised both statutory and constitutional claims. Because the judge below reversed the board’s decision permanently to rescind Bulger’s retirement allowance and ordered reinstatement of his pension, the judge did not reach Bulger’s claim that the forfeiture of his pension benefits constituted an excessive fine in violation of the Eighth Amendment to the United States Constitution. Citing MacLean v. State Bd. of Retirement, 432 Mass. 339, 348 n.11 (2000), Bulger contends that proper consideration of his constitutional claim would require factual findings by the judge as to the total value of the pension forfeiture involved. He further asserts that questions of law are not considered de nova on certiorari review. See Massachusetts Bay Transp. Auth. v. Auditor of the Commonwealth, 430 Mass. 783, 791 (2000). Bulger’s constitutional claim has not been briefed by the parties and is not presently before us.
The board has never suggested that Bulger misappropriated funds or property from any government unit in which he was employed prior to his retirement. Therefore, G. L. c. 32, § 15 (1) and (3), are not implicated in this matter. Similarly, because the criminal proceedings against Bulger arose under Federal law, the provisions of G. L. c. 32, § 15 (3A), setting forth the pension consequences of convictions of certain violations of Massachusetts law, namely G. L. c. 268A, § 2 (corruption to influence official acts), and G. L. c. 265, § 25 (extortion in relation to police or licensing duties), are not applicable. See Collatos v. Boston Retirement Bd., 396 Mass. 684, 687-688 (1986).
Canon 1 of S.J.C. Rule 3:12, as appearing in 407 Mass. 1301 (1990), states that the purpose of the code “is to define norms of conduct and practice appropriate to persons serving in the positions covered by the Code and thereby to contribute to the preservation of public confidence in the integrity, impartiality, and independence of the courts.” Pursuant to Canon 2 of S.J.C. Rule 3:12, as appearing in 407 Mass. 1301 (1990), “[a] Clerk-Magistrate shall comply with the laws of the Commonwealth, rules of court, and lawful directives of the several judicial authorities of the Commonwealth.” With respect to the performance of duties, Canon 3 (A) (1) of S.J.C. Rule 3:12, as appearing in 407 Mass. 1301 (1990), states that “[a] Clerk-Magistrate shall be faithful to the law and maintain professional competence in it as it relates to the performance of his or her duties.” Canon 4 of S.J.C. Rule 3:12, as appearing in 407 Mass. 1301 (1990), provides that “[a] Clerk-Magistrate shall perform the duties of Clerk-Magistrate impartially and should act at all times in a manner that promotes public confidence in the integrity and impartiality of the judicial branch of government.” Further, “[a] Clerk-Magistrate shall conduct personal affairs in such a way as not to cause public disrespect for the court and the judicial system.” S.J.C. Rule 3:12, Canon 4 (B). See SJ.C. Rule 3:12, Canon 5 (A), as appearing in 407 Mass. 1301 (1990) (same).
There is no dispute that at the time Bulger committed the crimes of perjury and obstruction of justice, in November, 1996, and January, 1998, he was still employed as a clerk-magistrate.