Search notes:

ORA-01786: FOR UPDATE of this query expression is not allowed

The error message ORA-01786: FOR UPDATE of this query expression is not allowed is thrown, for example, when mistakenly formulating a partition extension clause with for partition (…) instead of the correct partition for (…).

Example using aggregate function

create table tq84_ora_01786 (
    grp   varchar2(3) not null,
    val   number(7,2) not null
);

select
   sum(val)
from
   tq84_ora_01786
for update;

drop table tq84_ora_01786;

See also

Other Oracle error messages such as ORA-02014: cannot select FOR UPDATE from view with DISTINCT, GROUP BY, etc

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1759612203, '216.73.216.149', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/databases/Oracle/errors/ORA-01786_FOR-UPDATE-of-this-query-expression-is-not-allowed(51): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78