Thank you for the link.

The problem is that our application works fine with 10g,
with RAC 11i - even dbms_stats does not work (see provided code).
We have a standaolne version of Oracle 11i and application works fine, but does not work with RAC of the sam eversion. I assume there is something wrong related to RAC.