← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 757519] [NEW] Error while searching for account after upgrading to 6.0.2

 

Public bug reported:

In an invoice I am trying to change the account in an line and I get the
following error:

Environment Information : 
System : Linux-2.6.35-28-generic-i686-with-Ubuntu-10.10-maverick
OS Name : posix
Distributor ID:	Ubuntu
Description:	Ubuntu 10.10
Release:	10.10
Codename:	maverick
Operating System Release : 2.6.35-28-generic
Operating System Version : #50-Ubuntu SMP Fri Mar 18 19:00:26 UTC 2011
Operating System Architecture : 32bit
Operating System Locale : en_US.UTF8
Python Version : 2.6.6
OpenERP-Client Version : 6.0.1
Last revision No. & ID :Bazaar Package not Found !Traceback (most recent call last):
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/netsvc.py", line 489, in dispatch
    result = ExportService.getService(service_name).dispatch(method, auth, params)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/service/web_services.py", line 599, in dispatch
    res = fn(db, uid, *params)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/osv.py", line 122, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/osv.py", line 176, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/osv.py", line 167, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/addons/account/account.py", line 456, in name_search
    ids = self.search(cr, user, [('code', '=like', name+"%")]+args, limit=limit)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/addons/account/account.py", line 198, in search
    if (not (jour.account_control_ids or jour.type_control_ids)) or not args[pos][2]:
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 292, in __getattr__
    return self[name]
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 205, in __getitem__
    field_values = self._table.read(self._cr, self._uid, ids, field_names, context=self._context, load="_classic_write")
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 2940, in read
    result = self._read_flat(cr, user, select, fields, context, load)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 3060, in _read_flat
    res2 = self._columns[f].get(cr, self, ids, f, user, context=context, values=res)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/fields.py", line 597, in get
    cr.execute(query, [tuple(ids),] + where_params)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/sql_db.py", line 78, in wrapper
    return f(self, *args, **kwargs)
  File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/sql_db.py", line 131, in execute
    res = self._obj.execute(query, params)
ProgrammingError: syntax error at or near "child_of"
LINE 1: ...id IS NULL   OR  (account_account_type.company_id child_of '...
                                                             ^

I have a normal rule (not even touched it since setup) for account_account_type with the following details:
['|','|',('company_id','=',False),('company_id','child_of',[user.company_id.id]),('company_id.child_ids','child_of',[user.company_id.id])]

** Affects: openobject-server
     Importance: Undecided
         Status: New

-- 
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/757519

Title:
  Error while searching for account after upgrading to 6.0.2

Status in OpenERP Server:
  New

Bug description:
  In an invoice I am trying to change the account in an line and I get
  the following error:

  Environment Information : 
  System : Linux-2.6.35-28-generic-i686-with-Ubuntu-10.10-maverick
  OS Name : posix
  Distributor ID:	Ubuntu
  Description:	Ubuntu 10.10
  Release:	10.10
  Codename:	maverick
  Operating System Release : 2.6.35-28-generic
  Operating System Version : #50-Ubuntu SMP Fri Mar 18 19:00:26 UTC 2011
  Operating System Architecture : 32bit
  Operating System Locale : en_US.UTF8
  Python Version : 2.6.6
  OpenERP-Client Version : 6.0.1
  Last revision No. & ID :Bazaar Package not Found !Traceback (most recent call last):
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/netsvc.py", line 489, in dispatch
      result = ExportService.getService(service_name).dispatch(method, auth, params)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/service/web_services.py", line 599, in dispatch
      res = fn(db, uid, *params)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/osv.py", line 122, in wrapper
      return f(self, dbname, *args, **kwargs)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/osv.py", line 176, in execute
      res = self.execute_cr(cr, uid, obj, method, *args, **kw)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/osv.py", line 167, in execute_cr
      return getattr(object, method)(cr, uid, *args, **kw)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/addons/account/account.py", line 456, in name_search
      ids = self.search(cr, user, [('code', '=like', name+"%")]+args, limit=limit)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/addons/account/account.py", line 198, in search
      if (not (jour.account_control_ids or jour.type_control_ids)) or not args[pos][2]:
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 292, in __getattr__
      return self[name]
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 205, in __getitem__
      field_values = self._table.read(self._cr, self._uid, ids, field_names, context=self._context, load="_classic_write")
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 2940, in read
      result = self._read_flat(cr, user, select, fields, context, load)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/orm.py", line 3060, in _read_flat
      res2 = self._columns[f].get(cr, self, ids, f, user, context=context, values=res)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/osv/fields.py", line 597, in get
      cr.execute(query, [tuple(ids),] + where_params)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/sql_db.py", line 78, in wrapper
      return f(self, *args, **kwargs)
    File "/usr/local/lib/python2.6/dist-packages/openerp-server_9000/sql_db.py", line 131, in execute
      res = self._obj.execute(query, params)
  ProgrammingError: syntax error at or near "child_of"
  LINE 1: ...id IS NULL   OR  (account_account_type.company_id child_of '...
                                                               ^

  I have a normal rule (not even touched it since setup) for account_account_type with the following details:
  ['|','|',('company_id','=',False),('company_id','child_of',[user.company_id.id]),('company_id.child_ids','child_of',[user.company_id.id])]



Follow ups

References