This factory was the workplace of SpongeBob's best friend, Patrick Star. It was featured in several episodes of the show, and it's known for being a very strange and chaotic place.
While not actually a factory in the traditional sense, it was the place where Patrick "worked" as a "chum" making "old chum". It was more of a joke about Patrick's job and SpongeBob's loyalty.
Do you have any other details about the factory you're thinking of?