Genesis 40:1-8
Some time later, the cupbearer and the baker of the king of Egypt offended their master, the king of Egypt. 2 Pharaoh was angry with his two officials, the chief cupbearer and the chief baker, 3 and put them in custody in the house of the captain of the guard, in the same prison where Joseph was confined. 4 The captain of the guard assigned them to Joseph, and he attended them.
After they had been in custody for some time, 5 each of the two men—the cupbearer and the baker of the king of Egypt, who were being held in prison—had a dream the same night, and each dream had a meaning of its own.
6 When Joseph came to them the next morning, he saw that they were dejected. 7 So he asked Pharaoh’s officials who were in custody with him in his master’s house, “Why do you look so sad today?”
8 “We both had dreams,” they answered, “but there is no one to interpret them.”