
116 Cal.App.2d 419 (1953)
THOMAS P. MENZIES et al., Appellants,
v.
GEOPHYSICAL SERVICE, INC. (a Corporation) et al., Respondents.
Civ. No. 4390. 
California Court of Appeals. Fourth Dist.  
Mar. 2, 1953.
 Thomas P. Menzies, in pro. per., Harold L. Watt and James O. White, Jr., for Appellants.
 Johnston, Baker & Palmer for Respondents.
 GRIFFIN, J.
 In a third amended complaint plaintiffs and appellants Thomas P. Menzies and wife allege that they own a certain parcel of property in Kern County improved with a water well and pump which then produced approximately 2,250 gallons of water a minute; that in March, 1949, defendants and respondents wilfully, wantonly and without authority, and with intent to damage plaintiffs and their property, entered upon it and drilled holes in various places and placed explosive substances therein and caused them to detonate and explode; that violent concussions and vibrations of the earth and air shook the land and well of plaintiffs, causing great injury to the strata of the soil; that as a direct result, plaintiffs' well was shattered and the production of water therefrom was reduced and diminished from 2,250 gallons to approximately 1,750 gallons per minute, damaging plaintiffs' real estate so improved with the well, in the sum of $50,000 being the difference in the value of plaintiffs' property so improved by the water well before and immediately after the acts of said defendants; that as a further direct result of said acts plaintiffs' well, which was reasonably worth the sum of $13,000 immediately prior thereto, was wrecked, damaged and depreciated by the acts of defendants, in the sum of $2,755.87, in that the well became *421 clogged and obstructed with sand and gravel, and plaintiffs spent $1,271.25 in removing said sand and gravel and in installing new equipment; that the water level of the well was permanently reduced from approximately 85 feet below the surface to approximately 136 feet, and plaintiffs' pump was thereafter unable to lift water to the surface; that they spent $1,484.62 for a new pump and new tubing capable of lifting the water from the lower level resulting from said acts of the defendants, and for gravel to repair damage to the well resulting therefrom; that in doing the things alleged defendants acted maliciously and with wanton disregard of the rights of plaintiffs. Exemplary and punitive damages are also claimed in the sum of $1,000.
 As a second cause of action, plaintiff and appellant Jamie H Smith realleges these same acts pertaining to a parcel of property owned by him, that the property was improved with a well producing 2,000 gallons of water per minute and that after the detonation it was reduced to 1,500 gallons per minute; that the value of the real estate so improved before the acts complained of was $75,000, and afterwards was $25,000. Fifty thousand dollars is claimed for such damage. Additional damage for $33,590.91 is claimed for the difference in value of the well prior to and after the claimed acts of defendant. Exemplary and punitive damages for $1,000 are sought.
 A general and special demurrer to the third amended complaint was sustained. Twenty days to amend were allowed plaintiffs if they so moved the court. On August 20, 1951, plaintiffs filed a motion for permission to file a proposed fourth amended complaint, and served a copy thereof on defendants. This proposed complaint set forth similar allegations as to the claimed damage, with an enlarged description of the property, the usages to which it was put, and the nature of the damage suffered, i.e., that it was fenced and used for the production of crops and as shooting grounds for migratory game birds: that by reason of the lowering of the subterranean water level there was an increase in the cost of production of water by extending tubing to the lower level. The court, after hearing, struck out, on its own motion, all allegations pertaining to damage to the realty and allegations pertaining to exemplary damages and granted plaintiffs leave to file the fourth amended complaint as modified. Counsel for plaintiffs refused and advised the court to enter judgment accordingly so he could test the correctness of the court's ruling. Judgment for defendants was entered. *422
 Plaintiffs appealed and argue that both the third and fourth amended complaints contain sufficient allegations to state a cause of action for injury and damage to the realty as well as to the well and pump.
 [1] Defendants first argue that plaintiffs were obligated to file that portion of the fourth amended complaint allowed by the court and go to trial upon it; that the judgment entered was not one entered against them but that this is an appeal from a judgment requested by plaintiffs. We see little merit to this argument. The trial court, on its own motion, struck and emasculated the main portion of plaintiffs' cause of action pertaining to the realty. Plaintiffs were not obligated to go to trial on the remaining portion of the complaint if the court was in error as to its ruling. [2] On an appeal from a judgment entered against plaintiffs the ruling of the trial court striking a portion of plaintiffs' complaint may be reviewed. (Ross v. Flynn, 46 Cal.App. 401 [189 P. 293]; Code Civ. Proc.  956.)
 In Neal v. Bank of America, 93 Cal.App.2d 678 [209 P.2d 825], the court sustained an order of the trial court striking the complaint and proposed amendment to the complaint on the ground that they were frivolous and sham, and stated that the proper judgment to be entered was a judgment of dismissal, from which plaintiff could appeal and test the question.
 In Metzenbaum v. Metzenbaum, 86 Cal.App.2d 750, 752 [195 P.2d 492], the defendant demurred generally to the complaint. After sustaining the demurrer with leave to amend, plaintiff declined to do so. The court said plaintiffs must, then, stand upon the pleading as against all grounds, and if the complaint is objectionable on any ground, the judgment of dismissal must be affirmed.
 It is defendants' contention, in support of the trial court's ruling, that, from plaintiffs' allegations in the several complaints, it affirmatively appears that the damage attempted to be alleged by plaintiffs was damage to their wells and well water produced by existing wells; that the allegations as to damage to plaintiffs' land is frivolous and sham and the court was therefore authorized to strike these allegations from the complaint; that the allegation of $50,000 damages to the realty of each plaintiff, which is additional to the only damage specifically pleaded, i.e., well damage, is not only inconsistent with former verified pleadings, but is a conclusion of law inconsistent with particular allegations of well damage, *423 and that, under the circumstances, the special allegations must control, citing Denman v. City of Pasadena, 101 Cal.App. 769, 776 [282 P. 820]. We have examined the original complaint and the various amended complaints. Even in the first complaint it refers to damage and depreciation in value of plaintiffs' property. The other amended complaints refer to damage to the water well, for reduction in water production, for reduction in the value of the real property, and for costs of attempted repairs to the well. Although, at defendants' insistence, plaintiffs amended their complaint several times to elaborate more fully on the nature of the damage, there appears to be no inconsistency between the several pleadings or change of position as was indicated in Lee v. Hensley, 103 Cal.App.2d 697 [230 P.2d 159], or that the original complaint discloses a defect not curable by amendment, or that a wholly different cause of action is introduced, as in Klopstock v. Superior Court, 17 Cal.2d 13 [108 P.2d 906, 135 A.L.R. 318]; Reardon v. Balaklala Consol. Copper Co., 193 F. 189.
 [3] It has been definitely held that one whose real property is injured by another's wrongful and negligent act is entitled to such damage as will compensate him for the injury or loss sustained. (Givens v. Markall, 51 Cal.App.2d 374, 379 [124 P.2d 839]; 15 Am.Jur., p. 514,  106; O'Leary v. Herbert, 5 Cal.2d 416 [55 P.2d 834].) [4] In a proper suit for permanent damages to a freehold, the reason for the rule which ordinarily requires the measure of damages to be shown by proof of the value of the property before and after the commission of the acts complained of, is that the jury may determine, by subtracting one valuation from the other, what the amount of actual damages may be. (Givens v. Markall, supra; General Geophysical Co. v. Brown, 205 Miss. 189 [38 So.2d 703].)
 [5] If a thing destroyed, although it is a part of the realty, has a value which can be accurately ascertained without reference to the soil on which it stands or out of which it grows, the recovery may be the value of the thing thus destroyed or the cost of its repair. (Vol. 4 Sutherland on Damages, 4th ed. p. 3751,  1015; Greenebaum v. Taylor, 102 Cal. 624 [36 P. 957]; Civ. Code,  3333.) [6] These claimed damages, in the instant pleadings, have been separately stated, and are separate and distinct from the claimed permanent injury to the underground strata. Whether plaintiffs will be able to prove the allegations of their amended complaint is not the question before us. They were entitled to plead it, *424 and we conclude that the court erred in sustaining defendants' demurrer to the third amended complaint, and in striking from plaintiffs' proposed fourth amended complaint the allegations pertaining to damage to the realty. (Norton v. Bassett, 158 Cal. 425 [111 P. 253]; 21 Cal.Jur. p. 182,  126; Bacon v. Wahrhaftig, 97 Cal.App.2d 599 [218 P.2d 144].)
 The other contention of defendants is that the allegations pertaining to exemplary and punitive damages are frivolous and sham and should have been stricken.
 In Smpardos v. Piombo Const. Co., 111 Cal.App.2d 415 [244 P.2d 435], the question of exemplary damages was presented where there was a trespass on property held by plaintiff as a mining claim. Defendants entered, without his permission, maintained a powder magazine within 200 feet of his cabin and injured his personal property. The court sustained an award for such damages where it appeared that defendants were both oppressive and malicious in their trespass. Under section 3294 of the Civil Code exemplary damages may be awarded where a defendant has been guilty of "oppression, fraud, or malice, express or implied ..." [7] The allegations here are that defendants acted wilfully, unlawfully and maliciously in doing the acts charged, with deliberate intention to injure and damage plaintiffs' property. This is a sufficient allegation as against a general demurrer. (Davis v. Hearst, 160 Cal. 143 [116 P. 530]; Morgan v. French, 70 Cal.App.2d 785 [161 P.2d 800].)
 Judgment reversed with directions to the trial court to allow plaintiffs to file their fourth amended complaint, as proposed.
 Barnard, P. J., and Mussell, J., concurred.
