What does the following mean and how could it be used?
Good at the moment, bad in the long run?
One word to describe such situations is short-sighted.
To have converted so many parking spots to all-day meters may have raised revenues for the municipal coffers and made commuters happy, but now there's less space for shoppers to park for brief amounts of time, and small businesses in town are seeing a drop in the number of customers. The decision was short-sighted.
We can use that to say that something is temporarily good, but eventually will be negative.
An example might be someone who uses a lot of alcohol or drugs to feel pleasure. It may feel good at the moment, but will probably cause more problems than it's worth: for example, someone might get hurt trying to drive or walk, etc. Or someone might get sick and feel terrible the next day. Someone could keep using the substance and become addicted, etc.
The key to answering your question is probably understanding the meaning of in/over the long run which means
not immediately but at some time in the future