select 
	concat('update TEACHER set TEACHER.KEY_SERVICE_PROVIDER_REGIME = ', 
		SERVICE_PROVIDER_REGIME.ID_INTERNAL, 
		' where TEACHER.ID_INTERNAL = ', 
		SERVICE_PROVIDER_REGIME.KEY_TEACHER, ';') 
as "" from SERVICE_PROVIDER_REGIME;