hi, i use such a little programm to populate some OLAP objects,
but errors come out:
******************
ORA-34628: (MXSQL99) The SQL "DECLARE" command can only be used in a program,
and it must be compiled before it can be executed.
******************
the below script is my programm, please tell me how to correct it,
THX

begin
dbms_aw.execute('ALLSTAT');
dbms_aw.execute('SQL DECLARE grabprods CURSOR FOR SELECT prod_total, -
prod_category, -
prod_subcategory, -
prod_id -
FROM products');
dbms_aw.execute('SQL OPEN grabprods');
dbms_aw.execute('SQL FETCH grabprods LOOP INTO :APPEND aw_products_all -
:APPEND aw_prod_category -
:APPEND aw_prod_subcategory -
:APPEND aw_prod_id');
dbms_aw.execute('SQL CLOSE grabprods');
dbms_aw.execute('SQL CLEANUP');
dbms_aw.execute('UPDATE');
dbms_aw.execute('COMMIT');
end;
/