I have power coming into box from black and white wires. When wiring black to light switch and white to white leading to fixture, the breaker goes every time. When wiring the two whites together with power on, there are sparks. What am I doing wrong?
First working with power on is wrong, I am an electrician and rarely do this , if I do I usually wear hot gloves and other safety equipment. If the hot is coming in to the switch box the whites should be tied together then the black hot to the switch and the black to the lamp on the other side of the switch. With the white wire sparking and either the black disconnected or switch turned off you may be working on a switch loop, look in the box at the light and send us a clear photo of those wires if more than 1 set going to the light, especially if you see a black wire connected to a white in the box and we can provide better help. I would also change the lamp, I have had incandescent lamps internally short and trip a 20 amp breaker when turned on, but if you have a hot white wire it may be a switch loop so we need to figure that out.