It's a pet peeve of mine listening to some kid in a store tell me what his 'friends told him' about how to care for a battery. Nobody bothers to do the research. They just repeat the same dumb thing that was said back in 1980.
[ Begin battery rant ]
Different batteries are damaged in different ways by discharging. The charge/discharge cycle will eventually wear out EVERY battery. How many charges, of what available depth of charge you get varies by battery chemistry.
All rechargeable batteries gradually take less and less of a charge, but all recently made batteries will have a very, very SMALL "memory" problem compared to the damage done by fully discharging them beyond the point where they stop doing their job. Microscopic compared to charging them when they're HOT.
A lead-acid battery should never be completely discharged, or left uncharged. If a lead-acid battery is left unused on the shelf for about six months, it is often a goner. As a minimum, it will have lost a great deal of its useful charge capacity. Lots of car batteries and deep cycle batteries are wasted because they are removed and not left on some form of intermittent trickle charger.
Car batteries, UPS batteries, deep cycle batteries, and some rechargeable lantern batteries are lead-acid batteries.
DO NOT leave a UPS unplugged for extended periods (i.e. put it in a closet and "forget it" for a month). Find something for it to do, or get rid of it. Most will safely trickle-charge the battery even when "off". At a minimum, remember to drag it out and charge it up once in a while. A UPS that has been in storage for an extended period is likely to be useless for its intended purpose (unless you buy and install a new battery). At the very least, make sure the UPS is completely recharged before you put it away.
Other batteries besides lead-acid will only take longer to "go bad" if left in a discharged state, or allowed to slowly discharge themselves into a discharged state. If it has a rechargeable battery in it, dig it out, inspect and charge it once in a while. Power tools. Notebooks. PDA's. Toothbrushes.
Most kinds of batteries will be DAMAGED if discharged beyond a certain point. Somewhere above this point is the minimum a device with a "smart" battery controller will allow the battery to drain to. (i.e., there is still some "juice" in the battery, but the device cuts it off to protect the battery.) Most (not ancient) notebook computers, cel phones and such will have some intelligent battery handling built in, so you can't over-drain it. The notion to "completely discharge" it is to reduce the number of charge/discharge cycles. Period. Do not deliberately discharge it JUST to recharge it. You will certainly do more damage to the battery than by simply "topping it off". If you use it in 30 minute intervals for a day, yes, it can be left unplugged in between and used until it warns you to plug it back in. If you are done with it, plug it in. You don't have to DRAIN it. If it is nearly discharged, recharge it completely, rather than plug it in for a little while and unplug it for a little while. That can be very, very bad for it.
Many, but not all devices have a "smart" charger that will not over-charge batteries. Especially when expensive batteries are used. Over-charging a battery will "cook" it. Definitely not good. Pay attention to the instructions. If it says not to leave it plugged in "overnight", it has a "dumb" charger and you you will eventually cook the batteries by accident. It probably doesn't have the discharge control, either. Beware!
Devices without discharge protection (like most cordless power tools) should simply be recharged when they stop working well enough. You will do far more damage to the charge it can hold by fully discharging the cordless tool than any (always miniscule nowadays) "memory" effect if you deliberately discharge it until it stops moving under no load. Most power tools are Nickel Cadmium. You will reduce the life of all but the first generations (which were all toast long ago) batteries by discharging them to "zero".
Most kinds of batteries are damaged by high temperatures and large temperature changes. Trying to refrigerate it for a "fast" charge will generally damage them, too.
Most kinds of batteries will discharge themselves over time. You should definitely NOT buy old rechargeable batteries of any kind, or devices with integrated batteries that have not been used for a long time. Unless it's a good enough bargain that recycling the old battery and buying a replacement battery is worth it.
The 'rechargable alkaline' batteries from Rayovac are way cool for certain things. They're excellent for remote controls and flashlights and things. They don't take as many charges, but they'll sit in a remote control or flashlight or wireless mouse/keyboard as long as an alkaline battery would. Most rechargable batteries will be dead in two or three weeks, even when not used.
There is basically nothing you can do to make rechargeable batteries "immortal". They'll recharge near those "cycle life" numbers if you take care of them. They will die an early (and costly) death if you mistreat them.
Don't just go by what some joe off the street tells you. RTFM.
[ End battery rant ]