Elhanan, son of Jair
Elhanan son of Jair-Oregim the Bethlehemite ( "’Elḥānān ben-Ya‘rê ’Ōrəḡîm Bêṯhallaḥmî") appears in 2 Samuel 21:19, where he is credited with killing Goliath. As this contradicts the better-known story in 1 Samuel 17 in which it is the famous David who kills Goliath, the 4th century BC Book of Chronicles explains the second Goliath by saying (20:5) that Elhanan "slew Lahmi the brother of Goliath", possibly constructing the name Lahmi from the last portion of the word "Bethlehemite" (""beit-ha’lahmi"). The King James Bible translators modified 2 Samuel 21:18–19 to make it read as if Elhanan had slain Goliath's brother: "And there was again a battle in Gob with the Philistines, where Elhanan the son of Jaare–oregim, a Beth–lehemite, slew "the brother of" Goliath the Gittite, the staff of whose spear was like a weaver's beam", although the Hebrew text at this point makes no mention of the word "brother"; the medieval Jewish authors of the Targum Jonathan solved the problem by explaining Elhanan as an alternative name for David. However, this makes it difficult to explain why David is called "Elhanan" in verse 19 but consistently "David" in the verses that surround it (15, 16, 17, 21, 22). The most widely accepted explanation is that the storytellers have displaced the deed from the obscure Elhanan to the more famous character, David.
David
David is an important figure in Islam as one of the major prophets sent by God to guide the Israelites. David is mentioned several times in the Quran with the Arabic name داود, "Dāwūd", often with his son Solomon. In the Qur'an: David killed Goliath (2:251), a giant soldier in the Philistine army. When David killed Goliath, God granted him kingship and wisdom and enforced it (38:20). David was made God's "vicegerent on earth" (38:26) and God further gave David sound judgment (21:78; 37:21–24, 26) as well as the Psalms, regarded as books of divine wisdom (4:163; 17:55). The birds and mountains united with David in uttering praise to God (21:79; 34:10; 38:18), while God made iron soft for David (34:10), God also instructed David in the art of fashioning chain-mail out of iron (21:80); an indication of the first use of wrought iron, this knowledge gave David a major advantage over his bronze and cast iron-armed opponents, not to mention the cultural and economic impact. Together with Solomon, David gave judgment in a case of damage to the fields (21:78) and David judged the matter between two disputants in his prayer chamber (38:21–23). Since there is no mention in the Qur'an of the wrong David did to Uriah nor any reference to Bathsheba, Muslims reject this narrative.