Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
_AnonymousUser
Specialist III
Specialist III

Use a EXEC DBMS_STATS in a tOracleRow or another component ?

Hello,
Is it possible to do an "exec dbms_stats" with a Talend job ?
I am trying to execute this statement:
"EXEC DBMS_STATS.GATHER_SCHEMA_STATS('my_schema', cascade=>TRUE)"
with a tOracleRow but I get the error ORA-00900: invalid SQL Statement. It's the same with a ; at the end of the line.
When I execute this statement in SQLPlus/TOAD it works fine.
I'm on Oracle 11g, and Talend 4.0.3.
Any idea please ?
Thx in advance !
Sorry for my english.. 0683p000009MACn.png
Labels (2)
2 Replies
Anonymous
Not applicable

I created a stored proc then call it using the tOracle SP operator: CREATE OR REPLACE PROCEDURE REFRESH_STATS
(in_table_name varchar2)
as
BEGIN
DBMS_STATS.GATHER_TABLE_STATS(OWNNAME => 'BI_DM', TABNAME => in_table_name, CASCADE => TRUE, ESTIMATE_PERCENT => 100, DEGREE => DBMS_STATS.AUTO_DEGREE);
END;
/
Anonymous
Not applicable

Hi,
Just remove the EXEC command and type the remaining part of the statement with ";". Your wish will be fulfilled.
Cheers!
Thanks and Regards,
Pavan
Hello,
Is it possible to do an "exec dbms_stats" with a Talend job ?
I am trying to execute this statement:
"EXEC DBMS_STATS.GATHER_SCHEMA_STATS('my_schema', cascade=>TRUE)"
with a tOracleRow but I get the error ORA-00900: invalid SQL Statement. It's the same with a ; at the end of the line.
When I execute this statement in SQLPlus/TOAD it works fine.
I'm on Oracle 11g, and Talend 4.0.3.
Any idea please ?
Thx in advance !
Sorry for my english.. 0683p000009MACn.png