The Jataka, Vol. II, tr. by W.H.D. Rouse, , at sacred-texts.com
 "A ne’er-do-well did once," etc.--This story the Master told at Jetavana, about a nephew of Anāthapiṇḍika. This person had squandered an inheritance of forty crores of gold. Then the visited his uncle, who gave him a thousand, and bade him trade with it. The man squandered this, and then came again; and
once more he was given five hundred. Having squandered this like the rest, next time his uncle gave him two coarse garments; and when he had worn these out, and once more applied, his uncle had him taken by the neck and turned out of doors. The fellow was helpless, and fell down by a side-wall and died. They dragged him outside and threw him down there. Anāthapiṇḍika went and told the Buddha what had happened to his nephew. Said the Master, "How could you expect to satisfy the man whom I long ago failed to satisfy, even when I gave him the Wishing Cup?" and at his request, he proceeded to tell him an old-world tale.
Once upon a time, when Brahmadatta was reigning in Benares, the Bodhisatta was born as a rich merchant's son; and after his father's death, took his place. In his house was buried a treasure of four hundred million. He had an only son. The Bodhisatta gave alms and did good until he died, and then he came to life again as Sakka, king of the gods. His son proceeded to make a pavilion across the road, and sat down with many friends round him, to drink. He paid a thousand pieces to runners and tumblers, singers and dancers, and passed his time in drinking, gluttony, and debauchery; he wandered about, asking only for song, music, and dancing, devoted to his boon-companions, sunk in sloth. So in a short time he squandered all his treasure of four hundred millions,  all his property, goods, and furniture, and got so poor and miserable that he had to go about clad in rags.
Sakka, as he meditated, became aware how poor he was. Overcome with love for his son, he gave him a Wishing Cup, with these words: "Son, take care not to break this cup. So long as you keep it, your wealth will never come to an end. So take good care of it!" and then he returned to heaven.
After that the man did nothing but drink out of it. One day, he was drunk, and threw the cup into the air, catching it as it fell. But once he missed it. Down it fell upon the earth, and smashed! Then he got poor again, and went about in rags, begging, bowl in hand, till at last he lay down by a wall, and died.
When the Master had finished this tale, he went on:--
"When, proud and drunken, in a careless hour,
He broke the Bowl that gave him all this power,
Naked, poor fool! in rags and tatters, he
Fell in great misery. p. 295
"Not otherwise whoso great fortune owes,
But in the enjoying it no measure knows,
Is scorched anon, even as the knave--poor soul!--
That broke his Wishing Bowl."
Repeating these stanzas in his perfect wisdom, he identified the Birth: "At that time Anāthapiṇḍika's nephew was the rascal who broke the Lucky Cup, but I myself was Sakka."