Link to home
Start Free TrialLog in
Avatar of Chandan Pratihast
Chandan PratihastFlag for Japan

asked on

dbms_paralle_execute does not update

Hi

I am trying to update tables using the dbms_execute_parallel but it does not update table.  The things already checked are "job_queue_processes" it is 1000. The "parallel_min_servers" is 16. The "parallel_server" is FALSE is this the reason?

The table is CKP_PARALLEL. In this the column PPREM needs to be updated. User generated image The PPREM is 180.
Then executed the dbms_execute_parallel.
-------------------- PARALLEL STEP 1 ------------------------------------------
exec DBMS_PARALLEL_EXECUTE.CREATE_TASK('Update_TASK');
exec DBMS_PARALLEL_EXECUTE.CREATE_CHUNKS_BY_ROWID('Update_TASK','VM1DTA','CKP_PARALLEL',TRUE,1);
------------------------------------------------------------------------- 
DECLARE
 l_sql_stmt VARCHAR2(1000);
BEGIN
  l_sql_stmt := 'update CKP_PARALLEL set PPREM = PPREM + 10 WHERE ROWID BETWEEN :START_ROW_ID :END_ROW_ID';
  dbms_parallel_execute.run_task(
    task_name        =>'Update_TASK',
    sql_stmt         => l_sql_stmt,
    language_flag    => dbms_sql.native,
    parallel_level   => 5);
  
END;
/

Open in new window

User generated image
And then checking the premium (after commit).User generated image
What could be hte reason of this?
Oracle version 12C:Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production

Kindly suggest!
ASKER CERTIFIED SOLUTION
Avatar of slightwv (䄆 Netminder)
slightwv (䄆 Netminder)

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Chandan Pratihast

ASKER

Thank you, that bind variable name, after that had forgotten the "and".
Below correction and it worked.
...WHERE ROWID BETWEEN :START_ID and :END_ID';