Not to be snarky or anything, but don't people read their MMs anymore? I think this is the fourth or fifth thread that starts with a question about "How come the dragon can cast heal?" - though to be fair, most of those have been in RPG General.
In 3.0e, blue and red dragons, as well as all the metallic ones, are capable of casting spells from the cleric list as well as 2-4 domains. While it's not precisely spelled out, I always considered that to mean "They may choose them as if they were sorcerer spells, but they still take up spells known slots."