Long term is subjective. For tax purposes anything over 1 year is considered to be long term and is taxed at a lower rate.
If you want to be able to buy stocks and hold onto them until you are profitable there is no telling how long that would be, but according to history (with the acceptation of buying right before the great depression) holding onto strong stocks for 20 years should be enough to weather any big storms and still make a decent average annual return.
If you only have 5 years or under to invest you are taking a lot more risks because no one knows for sure what will happen in the next couple of years.
I would say if you are investing into the long term 5-10 years would be pretty aggressive, 10-20 years would be semi aggressive, and 20 years and over would be more conservative and more likely to give you a return that is somewhere close to the average stock market return.