Explanation:
Step 1: Find the differences
The first thing that we need to know is that another way of saying legislation is a statute.
So according to https://www.quora.com, "Legislation is the creation of statutes (another word for laws). Statutes are statutory law. Statutes, crafted and passed by legislatures and ratified by an executive authority, become law when the executive authority signs or ratifies them. They lay out in black-letter text, what the legislature intends the law to be." This means that statutes become laws which go through a process of being ratified which is mostly for a short-term because it can be changed.
On the other hand, according to https://www.quora.com, "Case law, also known as common law, is a compendium of court decisions, which establish what the courts hold to be equitable and enforceable law, which is just and sensible - and under a constitutional system, what the meaning of the law must be, in order to align with the dictates of the constitution." Case laws are the most concrete laws out there because of it being heavily impacted by the constitution during a case.
Answer: Legislation is mostly for short term and Case law is for a longer term