When shoving the dining table along to accommodate dinner guests either:
Unplug the lamp that is on the table or...
Remove the lamp to a safe and stationary place.
Otherwise, when the table slides from under the lamp you will have an almighty mess to clear up...:-( x