
167 Cal.App.2d 158 (1959)
JOHN G. OPPENHEIMER, Appellant,
v.
W. D. TAMBLYN et al., Defendants; R. ARNEBERGH, Respondent.
Civ. No. 23167. 
California Court of Appeals. Second Dist., Div. Three.  
Jan. 15, 1959.
 John G. Oppenheimer, in pro. per., for Appellant.
 Roger Arnebergh, City Attorney (Los Angeles), and William B. Burge, Deputy City Attorney, for Respondent.
 SHINN, P. J.
 Action against W. D. Tamblyn and others for malicious prosecution. Following the sustaining of a demurrer interposed by defendant Roger Arnebergh with leave to amend, plaintiff filed an amended complaint against Arnebergh only. Arnebergh demurred to the amended complaint. The court sustained his demurrer without leave to amend and entered judgment in his favor. Plaintiff appeals from the judgment dismissing the action as to Arnebergh.
 The amended complaint alleges: On or about February 15, 1955, defendant maliciously and without probable cause "filed a complaint and instituted a criminal prosecution in Los Angeles, California, against the plaintiff herein, charging that plaintiff had purportedly violated section 679 of the California Vehicle Code, in said city." Defendant "acted with oppression, fraud and malice" toward plaintiff. Plaintiff posted bail and paid $50 for the services of an attorney in defending against the charge. Plaintiff also alleges: "[A]fter a trial thereof, it was dismissed, and plaintiff's bail was exonerated in December, 1955." The prayer is for recovery of the attorney's fee and substantial general and exemplary damages.
 The first question to be considered is whether the amended complaint states the substance of a cause of action for malicious prosecution.
 [1] The elements of a cause of action for malicious prosecution are: (1) A judicial proceeding favorably terminated; (2) want of probable cause; and (3) malice. (Jaffe v. Stone, 18 Cal.2d 146 [114 P.2d 335, 135 A.L.R. 775].) [2] Where the complaint alleges no facts from which it can be concluded that the prior proceedings terminated favorably to the plaintiff, *161 it fails to state a cause of action. (Roos v. Harris, 203 Cal. 201 [263 P. 225]; Prentice v. Bertken, 50 Cal.App.2d 344 [123 P.2d 96]; Barrier v. Alexander, 100 Cal.App.2d 497 [224 P.2d 436].) [3] And, as the Supreme Court said in Jaffe v. Stone, supra, 18 Cal.2d 146, at page 150: "It is not enough, however, merely to show that the proceeding was dismissed. The theory underlying the requirement of favorable termination is that it tends to indicate the innocence of the accused, and coupled with the other elements of lack of probable cause and malice, establishes the tort. ... [4] [I]f the criminal proceeding goes to trial, it is ordinarily necessary, as a foundation for a malicious prosecution suit, that the plaintiff should have been acquitted. (Citations.) [5] The same fundamental theory is applied in testing a dismissal or other termination without a complete trial on the merits. If it is of such a nature as to indicate the innocence of the accused, it is a favorable termination sufficient to satisfy the requirement. If, however, the dismissal is on technical grounds, for procedural reasons, or for any other reason not inconsistent with his guilt, it does not constitute a favorable termination."
 Oppenheimer v. Tamblyn, 162 Cal.App.2d 293 [327 P.2d 574], was an appeal by plaintiff from a judgment of dismissal based upon an order sustaining, without leave to amend, the demurrer of defendant Wayne S. Vance to the original complaint in the present action. Plaintiff alleged therein that: "After due proceedings had in said criminal prosecution, it was dismissed." We held this allegation deficient as a pleading of favorable termination but we also held that although the complaint was subject to demurrer the court erred in sustaining the demurrer without leave to amend as it did not appear that the complaint could not have been amended to allege the fact that the charges against plaintiff had been dismissed on some ground which established or tended to indicate his innocence.
 [6] Plaintiff's allegation that the prior criminal prosecution was dismissed after a trial is little better than his superseded allegation that it was dismissed after "due proceedings." The amended complaint was vulnerable to demurrer for uncertainty. But it does not follow that the demurrer should have been sustained without leave to amend. A trial may consist of a determination of issues of fact or of law. It does not appear that there was not a trial of the factual issues. *162
 [7] Dismissal of the charge against Oppenheimer would have been tantamount to an acquittal and would have satisfied the requirement of a favorable termination if, at the close of the People's evidence, the court was convinced that it was insufficient to establish defendant's guilt and the dismissal was ordered on that ground.  [fn. 1] This conclusion is consistent with the rule that a dismissal of an information by a committing magistrate because of the insufficiency of the evidence to warrant holding the accused for trial constitutes a favorable termination. (Jaffe v. Stone, supra, 18 Cal.2d 146, 151, 158, and cases cited.) [8] It does not appear that plaintiff could not have amended his complaint to allege the fact, if it be a fact, that evidence was introduced at the trial, that he was placed in jeopardy, and that the case was dismissed for insufficient evidence. Since it is error to sustain a demurrer without leave to amend unless it is clear that a complaint cannot be amended to state a cause of action (39 Cal.Jur.2d 244), plaintiff should have been given leave to file a second amended complaint.
 The second question requiring discussion is whether the court erred in taking judicial notice that defendant is the city attorney of the city of Los Angeles, in ruling that defendant instituted proceedings against plaintiff in his official capacity, and in determining that he is immune from liability for malicious prosecution.
 A violation of Vehicle Code, section 679 (operating a vehicle upon a highway in an unsafe condition), is a misdemeanor. Defendant argues that it is the function of the city attorney to initiate misdemeanor proceedings, and that since it is alleged that he filed a complaint charging plaintiff with a misdemeanor, he could only have done so while acting in that capacity. We are not persuaded by this reasoning.
 Except as otherwise provided by law, all public offenses triable in inferior courts must be prosecuted by written complaint under oath subscribed by the complainant. (Pen. Code,  740.) It is the duty of the city attorney of Los Angeles to draw complaints and to prosecute all misdemeanors committed within the city and within the jurisdiction of the municipal court of the district in which the city is located. (Los Angeles City Charter  42(8) Stats. 1933, p. 2743; Gov. Code,  72193.) [9] But the jurisdiction of municipal courts *163 in misdemeanor cases arising out of violations of state law, as distinct from violations of city charter or city ordinance, is not limited to cases which have been instituted by a complaint issued by the city attorney. (People v. Barnhart, 37 Cal.App.2d Supp. 748 [94 P.2d 411].)
 [10] Furthermore, it does not appear upon the face of plaintiff's amended complaint that defendant initiated the misdemeanor prosecution in his official capacity on the basis of information received by him in the course of his official duties. For aught that appears, defendant might have himself been the complaining witness and have verified the complaint and thus initiated proceedings against Oppenheimer as a private citizen. Defendant urges the contrary in reliance upon Norton v. Hoffmann, 34 Cal.App.2d 189 [93 P.2d 250]. But that case is not in point. Chesebro and Hoffman were sued for the malicious prosecution of an attorney who was charged with practicing law without a license; the complaint alleged that Chesebro was City Attorney of the City of Los Angeles and that Hoffmann was his deputy. The question arising upon their demurrer was whether the acts committed by them were within the scope of their official duties as prosecuting officers of the city and it was held that they were. The plaintiff contended that they were acting in their official capacities and it was alleged that they prosecuted the case. The court said, at pages 194-195: "It would appear from the complaint that what they did was under color of what was treated as authority derived from the public offices which they held." Such a conclusion does not follow from the amended complaint in the present case. It did not allege that Arnebergh prosecuted the case against plaintiff.
 It should be a simple matter to obtain a determination upon a motion for summary judgment whether plaintiff can show that the dismissal amounted to an acquittal and that Arnebergh instituted the prosecution, if at all, in any capacity other than as city attorney. This would determine whether plaintiff is prosecuting the present action in good faith or is merely trifling with the court.
 The judgment is reversed.
 Wood (Parker), J., and Vallee, J., concurred.
NOTES
[fn. 1]  1. Upon the oral argument appellant stated "... After trial of said action it was dismissed for lack of sufficient evidence and plaintiff's bail was exonerated in December 1955" etc.
