Hi, i have a Zammad 3.4 in my server linux ubuntu 20.04 with nginx postgresql; i probed this application and create any users and i send a emails for create tickets and all work fine, but i need delete all accounts and i execute zammad run rails c and i put User.find(5) and give me information about of the account but when i put User.find(6).destroy not work as the others account and appear me this error
Why cant delete only this account?
The reason for this is that you’re probably trying to remove agent accounts.
The reference error message in this state means that account with ID 6 created or updated at least one user account. As there’s active references, you naturally can’t remove that database entry.
I’m ignoring your elasticsearch error messages on propose: That indicates a wrong configuration between ES and Zammad.
User.where(created_by_id: 6).update_all(created_by_id: 1)
User.where(updated_by_id: 6).update_all(updated_by_id: 1)
should do the trick.
Please note that removal of agents technically is possible, but not covered by our documentation. Usually you don’t want that anyway, because as you see above you’d need to remove tickets (because of references) or adjust data.
The following topics may affect you in that context as well:
Hi @MrGeneration i follow this and all work; i delete agent cause i just installed this app and to correct users created in excess I proceeded to eliminate this well until I adapt with all the modules. Thanks for all.
This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.