If I have a .sql file with this :
begin
exec dbms_stats.gather_table_stats('schema',table');
end;
/
Should I need to use :
call 'exec dbms_stats.gather_table_stats('schema',table')';
I cannot test it out because of system problems so i am posting my query here.
As far as I can tell, both are flawed – exec is used in SQL/Plus without a begin/end block, and call is definitely not PL/SQL; you’d also probably have to escape the single quotes inside your call statement.
You can just use