Its good to do both instead of depending only on any single one as saving can take care of your expenses at the time of emergencies and investment will help you in growing your money in long term so I think both are important.
That's right, they work in each individual case, depending on the circumstances in which we can compare their importance. I personally think that investing in it now does not matter.