Final Fantasy/Square was a big name (much bigger in japan), I don't remember money being the issue when it switched to Sony, even it it was, Nintendo surely would've been willing to match and/or beat Sony's offer. It was the data format, I believe. Square was pressuring Nintendo to make the N64 have a CD-ROM component, And when it decided against that, they ended their partnership and made buddies with Sony and their Playstation. The Playstation also had more potential, both in it's marketability and power, and that's not to mention the memory card issue.
Why they're still with Sony is based less on how much $$$ is receive from Sony, as it is from the astonishingly large user-base Sony consoles have had. More possible sales than the confused, and slightly abused Gamecube ever offered. This is going to change soon however, with the new, and obviously more popular nintendo consoles. The DS is getting a plethora of Square-enix games, Kingdom hearts, FF remakes, Dragon quest IV, IX, and monsters. The Xbox may also be getting Square games, given that they have been overly obvious in their multi-platform hints, and their recent interviews voicing the opinion that they want to triple their US revenue. They can do it too, they just have to break off from their restrictive relationship with Sony.