US president uses election campaign to attack political opponents after Democrats approved rules for the hearings as the proceedings go public.