If an action or proceeding is commenced by or against a county, city, or other political subdivision or agency of the state involving the title to or the boundaries of tidelands or submerged lands that have been or may hereafter be granted to it in trust by the Legislature, the State of California shall be joined as a necessary party defendant in the action or proceeding. Service of summons shall be made upon the Chair of the State Lands Commission and upon the Attorney General, and the Attorney General shall represent the state in all the actions or proceedings. If judgment is given against the state in the action or proceeding, costs shall not be recovered from the state.
Ca. Pub. Res. Code § 6308