The first Sorcery Merchant you encounter is in the safe, early area of the New Londo ruins. He acts as both a Blacksmith and a Sorcery seller. Don;t worry, if you don't go over the bridge, nothing will attack you there despite its ominous appearance.
Miracles are from the guy in bulky armor in Firelink Shrine. You either join Way of the White to get them early on, or you wait until later and he'll sell them to you anyway.
Pyromancy is from a NPC you save in the Depths.
The "true" Sorcery Merchant is saved in the Lower area of undead Burg, a bit before the Capra Demon. --- Cyril: Not so innocent. The mind is its own place, and in itself can make a Heav'n of Hell, a Hell of Heav'n.