You may find the verse an awkward one. Of course, God wants us to be as happy as we can be. The Lord wants us to go on a pandemonium like how the people at the Etihad Stadium celebrated after Sergio Aguero blasted the game-winner for Manchester City against Queen's Park last month for the Barclays Premier League championship, but God sometimes allows the bad news to come upon us for a reason. When two of my classmates died, I was really anxious, but He was there to comfort me. When my laptop, cellphone, and even my wallet were snatched, it was God who made me move on.
It's just like the ManC-QPR (R is for Rangers) game mentioned above. You may be as super festive as Pablo Zabaleta when you received many breakthroughs, like when he scored his one and only English league goal in that game. But here comes a time of defeats and hardships, and you are on the verge of giving up. You are depressed, anxious, sorrowful, simply the saddest man in the world in your view, like how the City fans felt when the team conceded two Queen's Park goal later and cross-town rivals Manchester United, who were also chasing for the Barclays championship, were winning in another game elsewhere.
Ecclesiastes 7:3, however, tells us that it's OK to be sad. In fact, the verse says it's better to be frustrated than having fun and sadness is, guess what, GOOD for the heart and even gains wisdom (Ecc. 7:4). Now you may be doubting, "If the Bible is God's Word, then why He is telling us that sadness is better than happiness?" Again, He wants us to be happy, but He's saying here that you can learn more in defeats than in victories. Michael Jordan, arguably the greatest athlete ever lived, even said in an interview that if not for the buzzer-beating game winners that he missed, he would have not been the best player ever. And the most important thing of all, God wants to reveal His power to us. When my registration matters this semester had gone mad, I was really depressed, but He promised me that He will do the mighty works, and indeed, He made possible the impossible. Now, from someone who's thinking of moving to another school, I got a chance to graduate in my current school (in two years, hopefully). It's just like scoring two goals in a span of 75 seconds to steal the win like what Manchester City exactly did.
God does not want us to be sad, but He said that it's OK to be sad. Why? To sum it up, He means that if we want happiness, as in TRUE HAPPINESS, all we need is to come to Him. In the end, what you think are the times that He's miles away from us are actually the cases that the Lord is just at pointblank range from us. All we need when we get sad is to accept His comfort and entrust everything in Him. God is our true source of happiness.
In this world you will face trouble, but take heart. [Jesus Christ has] overcome the world. (John 16:33b)