Is there any such thing as a bad meditation? I've always been told that there is no such thing as a bad meditation. No matter what happens it is OK. In fact the meditator is a bad judge of the effectiveness and efficacy of any sit even if those concepts did have meaning. However I was reading Everyday Zen by Charlotte Joko Beck and she said that she encounters people who have been meditating who are frankly wasting their time. She says they may as well have been practicing their golf swing for 20 years. Ooohhhh harsh.

So what's going on here? Is there really no such thing as a bad meditation and every sit is just grist for the mill. Or is it possible to waste your time and potentially waste years. Is 'there is no such thing as a bad meditation' just something you tell beginners to motivate them - a kind of expedient means?
In the Gopaka-Moggallana Sutta (MN 108), Ananda points out that the Buddha didn't speak in praise of all types of meditation:

“The Blessed One, brahmin, did not praise every type of meditation, nor did he condemn every type of meditation. What kind [14] of meditation did the Blessed One not praise? Here, brahmin, someone abides with his mind obsessed by sensual lust, a prey to sensual lust, and he does not understand as it actually is the escape from arisen sensual lust. While he harbours sensual lust within, he meditates, premeditates, out-meditates, and mismeditates. He abides with his mind obsessed by ill will, a prey to ill will … with his mind obsessed by sloth and torpor, a prey to sloth and torpor … with his mind obsessed by restlessness and remorse, a prey to restlessness and remorse … with his mind obsessed by doubt, a prey to doubt, and he does not understand as it actually is the escape from arisen doubt. While he harbours doubt within, he meditates, premeditates, out-meditates, and mismeditates. The Blessed One did not praise that kind of meditation.&quot;
(Bodhi, Trans.)

This seems like an obvious answer; just because something is called meditation doesn't make it wholesome. A hunter may spend his time meditating on how to catch a deer (pre-meditated murder), or one may spend an entire sitting meditation fantasizing about sensual pleasure.
A common example of this is the case where a meditator gets stuck on the ten vipassanupakilesa (imperfections of insight), like visions, rapture, quietude, etc., and mistakes them for the path. As a result, as you have read, a meditator can spend years basically going nowhere, just using meditation as an escape into these pleasant but meaningless experiences.
What isn't so clear cut, perhaps what you are really asking, is whether there is any condition that arises in meditation that one should avoid when cultivating wholesome meditation (proper samatha or vipassana). In this case, the answer is generally &quot;yes&quot; for samatha and generally &quot;no&quot; for vipassana.
In samatha meditation, where the object is absorption, one should avoid a great number of things; anything that is an obstruction to calm. Noises, pain, sickness, even indigestion, can all get in the way of your attainment of calm. Sitting in the wrong position can be an impediment, so the Buddha recommended the full-lotus with one's back perfectly straight. When one's mind enters into unwholesome thoughts or emotions, one should avoid such mental activity, replacing it with its opposite or coaxing the mind back towards wholesomeness.
As catpnosis points out, one should also not practice samatha against one's character type; a person of angry character should avoid asubha (loathsomeness) meditation, for example.
In vipassana, where the object is insight into reality, almost every experience is a valid meditation object; almost, because there may be cases where an experience may be physically harmful to the meditator (e.g. dangerous situations or physical injury) or a cause for cultivating unwholesomeness (e.g. getting caught up in obsessive thoughts or emotions). In some cases it is necessary to change one's posture from sitting to walking or vice versa to deal with these situations.