Oh, and I’m pretty sure it was Sterling Holloway who sang it.
Well, I searched that one out for years snd finally found it. (No doubt you are reading this ten years later; and worth the wait.)
The song is “The Ballad of Jack and the Beanstalk” by Jerry Livingston, from a 1956 TV special (it starred Joel Grey as Jack, with Arnold Stang as the giant, or rather his secretary - there was no giant, just a big pair of feet if I remember correctly).
You can hear the song on Spotify, last I checked. Captain Kangaroo played it a lot - it’s catchy.