Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0002241Openbravo ERP01. General setuppublic2007-11-08 11:552008-06-12 09:43
egoitz 
psarobe 
normalminoralways
closedfixed 
5
 
2.40alpha-r2 
No
Core
No
0002241: Delete client produces two errors
Steps:
General Setup>Client>Delete Client


Description:
When I try to delete the big bazar client if i have logged with big bazar role it works well, but if i have logged with system adiministrator it produces two errors.
the errors are attached in a file.


Enviroment:
windows xp
version 2.35
oracleXE
firefox 2
No tags attached.
Issue History

Notes
(0005830)
user71   
2005-06-01 00:00   
(edited on: 2008-06-12 09:43)
This bug was originally reported in SourceForge bug tracker and then migrated to Mantis.

You can see the original bug report in:
https://sourceforge.net/support/tracker.php?aid=1828187 [^]
(0002617)
egoitz   
2007-11-08 16:00   
(edited on: 2008-06-12 09:23)
Logged In: YES
user_id=1853880
Originator: YES

i have seen that when the error ocurrs in the ad_alertrecipient there are some rows that in the ad_role_id (that is a foreign key) has a ad_role_id that was big bazaar admin's role, and it is why the constraint can be enabled.
And in the m_attributesetinstance we can find a row where his ad_attributeset_id column(foreign key) has a value that does not appear on the m_attributeset table (in the primary key)
(0002618)
psarobe   
2007-11-15 12:24   
(edited on: 2008-06-12 09:23)
Logged In: YES
user_id=1500703
Originator: NO

The two errors have to be with the data of Big Bazaar. To fix this you have to do before execute the process:

update m_attributesetinstance set m_attributeset_id=0 where m_attributesetinstance_id=0;

update ad_alertrecipient set ad_client_id=1000000 where ad_role_id=1000000;

But if you have executed the process, then you have to do:

update m_attributesetinstance set m_attributeset_id=0 where m_attributesetinstance_id=0;

update ad_alertrecipient set ad_role_id=0 where ad_role_id=1000000;

And then in order to put the constraints enable, go to each table and put them enable