Making your way to Spear Pillar in Pokémon Diamond, Pearl, or Platinum involves a longer journey, so here's the full route.
Start by clearing out the entire warehouse in Veilstone and battling everyone inside. That earns you the Galactic Key, which lets you move through the whole Veilstone HQ. There you'll face off against Cyrus. Next, take the yellow warp panel ahead by standing on the big yellow dot, and keep progressing through the building until you reach the room where the three lake Pokémon are held. Battle the Grunt there and free them.
Then fly to Eterna City and head to Mt. Coronet. A Grunt will direct you to the Hearthome entrance. Using Surf, Strength, and Rock Climb, work your way to the summit, going outside the mountain at times to walk around it. At the top, you'll reach Spear Pillar, team up with your rival, and battle Commanders Mars and Jupiter, followed by Cyrus, and finally Dialga. Good luck!
One note: some players get stuck not on the ancient wall, but on a specific Galactic Grunt near the end who keeps insisting he's lost and has no Pokémon. If that's your snag, double-check you've cleared the earlier Grunts and events, as that dialogue usually means a prior step wasn't completed.