EXHIBIT NOS. 5.1 AND 23.1 January 28, 1997 St. Mary Land & Exploration Company 1776 Lincoln Street, Suite 1100 Denver, CO 80203 Re: Registration Statement on Form S-3 Gentlemen: St. Mary Land & Exploration Company, a Delaware corporation (the "Company"), is registering for sale up to 2,300,000 shares of its $0.01 par value common stock (the "Shares"). It is proposed that Shares be registered pursuant to a Registration Statement on Form S-3, File No. 333___________ (the "Registration Statement"), under the Securities Act of 1933, as amended (the "Act"), filed with the Securities and Exchange Commission (the "Commission") on January 28, 1997. In rendering the following opinion, we have examined and relied only upon the documents and the reports (verbal and written) as we deemed necessary in rendering the opinion, including the Certificate of Incorporation of the Company and amendments thereto, the Bylaws of the Company as amended, and authorizing Minutes of the Company. We have not undertaken, nor do we intend to undertake, any independent investigation beyond such documents and records, or to verify the adequacy or accuracy of such documents and records. Additionally, we have consulted with Officers and Directors of the Company, and have obtained such statements and representations with respect to matters of fact as we considered necessary or appropriate in the circumstances to render the opinions contained herein. We have not independently verified the content of the factual statements made to us in connection therewith, nor the veracity of such representations, nor do we intend to do so. Based upon and subject to the foregoing, it is our opinion that: (i) The Shares to be offered and/or sold, subject to effectiveness of the Registration Statement and compliance with any applicable blue sky laws, when issued and delivered against payment therefor in accordance with the terms of the Registration Statement, will constitute legally issued, fully paid and nonassessable shares of Common Stock of the Company. (ii) The Shares to be offered as part of the Registration Statement have been duly authorized, and, when duly executed by the Company the effectiveness of the Registration Statement, and compliance with applicable blue sky laws, when issued and delivered in accordance with the Underwriting Agreement and as set forth in the Registration Statement, will have been legally issued and will constitute valid and binding obligations of the Company in accordance with their terms, subject to: (a) applicable bankruptcy, insolvency, reorganization, moratorium or other similar laws of general application (including, without limitation, general principles of equity, whether considered in a proceeding in equity or at law), now or hereafter in effect relating to creditors' rights and claims generally, and/or general laws generally affecting or relating to the enforcement of creditors' rights, including, but not limited to Section 547 of the Federal Bankruptcy Reform Act of 1978; and (b) the remedy of specific performance and injunctive and other forms of equitable relief which are subject to equitable defenses, and to the discretion of the court before which any proceeding therefore may be brought. We hereby consent to the filing of this opinion as an exhibit to the Registration Statement; to the filing of this opinion in connection with such filings of applications as may be necessary to register, qualify or establish eligibility for an exemption from registration or qualification of the securities under the blue sky laws of any state or other jurisdiction; and to the reference to this firm in the Prospectus under the heading "Legal Matters." In giving this consent, we do not admit that we are in the category of persons whose consent is required under Section 7 of the Act or the rules and regulations of the Commission promulgated thereunder. The opinions set forth herein are based upon the federal laws of the United States of America, and the laws of the State of Colorado, and corporate laws of Delaware, all as now in effect. We express no opinion as to whether the laws of any particular jurisdiction apply, and no opinion to the extent that the laws of any jurisdiction other than those identified above are applicable to the subject matter hereof. The information set forth herein is as of the date of this letter. We disclaim any undertaking to advise you of changes which may be brought to our attention after the effective date of the Registration Statement. Very sincerely, /s/ Cohen Brame & Smith Professional Corporation Cohen Brame & Smith Professional Corporation