← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 723355] Re: Postgres Views ProgrammingError more than one row returned subquery

 

Actually not the warehouse view, but Purchase > Purchase Analysis

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/723355

Title:
  Postgres Views ProgrammingError more than one row returned subquery

Status in OpenERP Modules (addons):
  New

Bug description:
  In a sample database you would not notice this issue.

  Please issue the following query:
  SELECT category_id, COUNT(name) FROM product_uom WHERE uom_type='reference'
  GROUP BY category_id; -- HAVING count(name) > 1

  If it has any row where count(name) > 1, it will return this error
  File "/usr/local/lib/python2.6/dist-packages/openerp-server/sql_db.py", line 131, in execute
      res = self._obj.execute(query, params)
  ProgrammingError: more than one row returned by a subquery used as an expression

  To bypass the issue do this
  It is in addons/account/report/account_invoice_report.py:92, where a "LIMIT 1"

  There is another view with a similar problem in the GTK Client
  warehouse views



References