Title: | Oracle |
Notice: | For product status see topics: UNIX 1008, OpenVMS 1009, NT 1010 |
Moderator: | EPS::VANDENHEUVEL |
Created: | Fri Aug 10 1990 |
Last Modified: | Fri Jun 06 1997 |
Last Successful Update: | Fri Jun 06 1997 |
Number of topics: | 1574 |
Total number of notes: | 4428 |
We are trying to run a blanket 'analyze table' or 'analyze index' on an Oracle v7.3.2.2 database for Peoplesoft GL (2000 tables). It would be very helpful to us and our customers if we could accomplish this with minimal effort and execution time. Here is an example of what we attempted- SYNTAX assistance required here :-) SVRMGR> select "analyze table " table_name from all_tables where 2> table_name like 'PS%' " compute statistics" ; table_name like 'PS%' " compute statistics" * ORA-00933: SQL command not properly ended Thanks, Lyndon Handy Americas Benchmark Program Digital Equipment
T.R | Title | User | Personal Name | Date | Lines |
---|---|---|---|---|---|
1548.1 | give this a try | ALFAM7::GOSEJACOB | Wed Apr 23 1997 05:27 | 22 | |
re .0 > SYNTAX assistance required here :-) Alright here you go: set heading off set feedback off spool analyze.sql select 'analyze table ' || RTRIM(table_name) || ' compute statistics;' from all_tables where table_name like 'PS%'; spool off @analyze This should do what you are looking for. Good luck with your benchmark. Cheers from the European DBTC Martin | |||||
1548.2 | Thanks- looks good | TROOA::HANDY | L. Handy, MCSE DTN 626-3210 | Wed Apr 23 1997 12:56 | 4 |
Wonderful! Thanks, and I will keep this in our Exchange public folder for all to share. Lyndon |