health
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Health] Need a little help with and upgrade


From: shane dockery
Subject: [Health] Need a little help with and upgrade
Date: Mon, 14 Apr 2014 10:10:20 -0500

GM all,


I am trying to upgrade from 2.2. to 2.4 but i get this error with theassociated traceback:-

Sun Apr 13 13:13:23 2014] WARNING:init:unable to add 'UNIQUE(name)' constraint on table gnuhealth_healthprofessional !
If you want to have it, you should update the records and execute manually:
ALTER table "gnuhealth_healthprofessional" ADD CONSTRAINT "gnuhealth_healthprofessional_hp_uniq" UNIQUE(name)
Traceback (most recent call last):
  File "/usr/local/bin/trytond", line 111, in <module>
    trytond.server.TrytonServer(options).run()
  File "/usr/local/lib/python2.6/dist-packages/trytond/server.py", line 124, in run
    Pool(db_name).init(update=update, lang=lang)
  File "/usr/local/lib/python2.6/dist-packages/trytond/pool.py", line 151, in init
    lang=lang)
  File "/usr/local/lib/python2.6/dist-packages/trytond/modules/__init__.py", line 399, in load_modules
    load_module_graph(graph, pool, lang)
  File "/usr/local/lib/python2.6/dist-packages/trytond/modules/__init__.py", line 235, in load_module_graph
    cls.__register__(module)
  File "/usr/local/lib/python2.6/dist-packages/trytond/modules/health/health.py", line 238, in __register__
    super(HealthProfessional, cls).__register__(module_name)
  File "/usr/local/lib/python2.6/dist-packages/trytond/model/modelsql.py", line 141, in __register__
    table.add_constraint(ident, constraint)
  File "/usr/local/lib/python2.6/dist-packages/trytond/backend/postgresql/table.py", line 395, in add_constraint
    self._update_definitions()
  File "/usr/local/lib/python2.6/dist-packages/trytond/backend/postgresql/table.py", line 128, in _update_definitions
    (self.table_name,))
  File "/usr/local/lib/python2.6/dist-packages/trytond/backend/postgresql/database.py", line 309, in execute
    return self.cursor.execute(sql, params)
psycopg2.InternalError: current transaction is aborted, commands ignored until end of transaction block.

I have done this modification to to the health.py with the same  results:-

if TableHandler.table_exist(cursor,'gnuhealth_physician'):
            TableHandler.table_rename(cursor,'gnuhealth_physician', 'gnuhealth_healthprofessional_hp_uniq').

What can I do to resolve same?

Thank you as always, 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]