
538 So.2d 130 (1989)
Antone KOULIAS, Appellant,
v.
TARPON MARINE WAYS, Appellee.
No. 88-560.
District Court of Appeal of Florida, First District.
February 10, 1989.
*131 John G. Thompson, of Yanchuck, Thompson, Young, Berman, Latour, P.A., Tarpon Springs, for appellant.
Nancy L. Cavey, St. Petersburg, for appellee.
JOANOS, Judge.
Antone Koulias has appealed from an order of the deputy commissioner holding that his heart attack was noncompensable and denying his claim for benefits with regard to a shoulder injury. We affirm in part and reverse in part.
Koulias was employed by Tarpon Marine Ways (Tarpon) as a boat carpenter when he received an electric shock from a sander he was operating. The shock caused him to lose his balance and he wrenched his right shoulder catching himself to prevent a fall. At least 48 hours after receiving the shock, Koulias suffered a heart attack, from which it is undisputed he is now permanently disabled. Koulias subsequently filed a claim for wage loss and/or permanent total disability benefits with regard to both the heart attack and the right shoulder injury. Following a hearing at which conflicting medical opinions as to causation were expressed, the deputy found that the electric shock had no causal relationship to Koulias' heart attack. He also dismissed Koulias' claim with regard to the shoulder injury in that "[h]is inability to get out and find work is because he is permanently and totally disabled from his unrelated heart condition."
Koulias has argued first that the deputy erred in determining the causation issue based on his acceptance of the opinion of a doctor who examined Koulias only once over the opinion of Koulias' treating physician. It is the deputy commissioner's *132 function to determine credibility and resolve conflicts in the evidence, and he may accept the testimony of one physician over several others. The acceptance and rejection of medical testimony rests with the deputy, and his discretion should not be disturbed unless the medical testimony itself fails to meet the test of the substantial evidence rule. Griffith v. McDonalds, 526 So.2d 1032, 1033 (Fla. 1st DCA 1988). In this case, the medical opinion relied on by the deputy was based on objective testing as well as on the doctor's experience and observation. We also note that Koulias' treating physician did not treat him at the time of the heart attack, but assumed his care at least six months later. Therefore, any additional weight to which his opinion as to causation might be entitled was lessened. We further find that the deputy sufficiently explained his acceptance of one medical opinion over another and that Koulias' argument on that point is also without merit.
However, it was error for the deputy commissioner to dismiss Koulias' claim relative to his compensable shoulder injury based solely on the permanent total disability suffered from the noncompensable heart attack. While disability resulting solely from a second, noncompensable accident is not compensable, if on the date of the noncompensable accident the claimant is still suffering from the effects of the first, compensable accident, it does not follow that he is entitled to no compensation. McPherson v. Broward County School Board, 527 So.2d 238, 239 (Fla. 1st DCA 1988). Benefits may be awarded for either disability or medical care which is causally related to the compensable accident and injury in the absence of the second, noncompensable accident, and should include all medical care necessary for treatment of the compensable injury. Newhouse v. Volusia County School Board, 474 So.2d 1222 (Fla. 1st DCA 1985).
In this case, no findings were made with regard to Koulias' entitlement to disability or medical care relative to the shoulder injury as a separate entity from the noncompensable heart condition. We therefore reverse the deputy's outright denial of the claim for that injury and remand for additional findings on the disability and medical care which is causally related to the compensable injury.
BOOTH and MINER, JJ., concur.
