As the title says, in an Oracle 10g database, I’d like to create a query that will generate a set of ANALYZE INDEX commands for every index owned by a certain user. I’m a complete layman when it comes to database topics, so please keep answers as dummy-proof as possible, thanks!
Share
As you’re on Oracle 10g you really ought to be using DBMS_STATS instead. That could be implemented as simply as …
There are other parameters: check out the documentation.
If you want to generate stats for some other user’s indexes use ALL_INDEXES instead, and restrict on OWNER.
If your heart is set on ANALYZE then