I don’t think that pickles are “rotted cucumbers”. ? Seems like canned items (not including uncooked meat or fish) should not be included as “rotten”, but that is JMHO, and I am not some type of food scientist (nor did I stay at a Holiday Inn Express any time lately).
Yes, there is a difference between fermenting and rotting. With most fermented foods, special precautions are taken (such as boiling, drying, adding salt, sugar, spices etc) to make sure that only the fermentation process happens, and other bacterial processes that contribute to “rot” are stopped.
Everyone knows pickles are cucumbers soaked in evil.