Why Oracle is saying not a GROUP BY expression?

后端 未结 4 1485
不知归路
不知归路 2020-12-21 15:58

I am Trying to retrive data from the Oracle database table with following conditions

  1. All entries found by zip-code should be grouped, sorted by zip-code desce
4条回答
  •  不知归路
    2020-12-21 16:24

    It works in MySQl because MySQL has a shoddy interpretation of SQL.

    In any proper dialect, anything in the SELECT or ORDER BY clauses needs to be either an aggregate function, or a GROUPed expression.

    At the very least, you're going to need to group by ba.uuid, lastname and city.

提交回复
热议问题