Hello Mr. Pink,
When electrolysis is performed on an industrial scale, it is performed in a Chlor-Alkali plant. Salt (as NaCl) is dissolved into water until it is saturated. Then the salt-saturated-water is placed into a vessel with two electrodes (negatively charged, and positive charges). The NaCl molecule separates to form Caustic Soda (Sodium Hydroxide) at one electrode and forms Chlorine gas at the other electrode.
Chlorine gas (very poisonous) is collected at one end, and sodium hydroxide is removed at the other end.
I hope this helps,
Eugene