Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Symfony Messenger - ORA-02014: cannot select FOR UPDATE from view #33718

Copy link
Copy link
Closed
@DasBen

Description

@DasBen
Issue body actions

Symfony version(s) affected: 4.3

Description

In AbstractOracleDriver.php line 57:

  An exception occurred while executing 'SELECT a.* FROM (SELECT m.* FROM 
messenger_messages m WHERE (m.delivered_at is null OR  
   m.delivered_at < ?) AND (m.available_at <= ?) AND (m.queue_name = ?) ORDER BY 
available_at ASC) a WHERE ROWNUM <= 1 FOR UPDATE' with params ["2019-09-26 10:26:28", "2019-09-26 11:26:28", "default"]:                                                     
                                                                                                                         
  ORA-02014: FOR UPDATE kann nicht auf View mit DISTINCT, GROUP BY usw. augewandt werden                                         

In OCI8Exception.php line 16:

  ORA-02014: FOR UPDATE kann nicht auf View mit DISTINCT, GROUP BY usw. augewandt werden  

How to reproduce
Use oracle12 with symfony 4.3 and messenger

Was affected with this issue too: #32427
Fixed it by removing the "T" from that dateformat

I think the query must be rewritten, so that the rownum filter is not on the outer sql. Maybe like this? https://stackoverflow.com/a/6337356/1953421

Could not try, because i do not know where to change the sql for the messenger select.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.