how to delete a particular user from User(sys_user) table.

praveen1231
Tera Contributor

Hi,

My scenario is - I had created a new catalog item variable called User(Referrence field). When I select any particular user (e.g. Abel Tuter) and submit the catalog item record, selected user (Abel Tuter) needs to delete permanently from the User(sys_user) table. Please let me know if you have any idea regarding this. Thanks

1 ACCEPTED SOLUTION

Hi @praveen1231,

 

I understand that is the requirement, however part of our job is to give advice.

 

Not every requirement should be fulfilled if there are better ways to do it, or if it is better to not do it at all.

 

I'll leave it up to you what to do with that. Just keep in mind a trusted advisor is valued even more than a good developer. 

 

That being said, since you are using a catalog item, the easiest way to handle it, is to create a flow with flow designer.

 

Lookup the user from the variables, update the user, or delete if there is is no other way forward.


Help others to find a correct solution by marking the appropriate response as accepted solution and helpful.

View solution in original post

11 REPLIES 11

Peter Bodelier
Giga Sage

Hi @praveen1231,

 

I wouldn't recommend deleting users, since all references to the user will be broken.

Why not just set the users inactive/locked_out?


Help others to find a correct solution by marking the appropriate response as accepted solution and helpful.

Sorry Mr. @Peter Bodelier, but my requirement is needed to delete the user when it is selected in reference field. Please let me know if you have any idea regarding this. Thanks

Hi @praveen1231,

 

I understand that is the requirement, however part of our job is to give advice.

 

Not every requirement should be fulfilled if there are better ways to do it, or if it is better to not do it at all.

 

I'll leave it up to you what to do with that. Just keep in mind a trusted advisor is valued even more than a good developer. 

 

That being said, since you are using a catalog item, the easiest way to handle it, is to create a flow with flow designer.

 

Lookup the user from the variables, update the user, or delete if there is is no other way forward.


Help others to find a correct solution by marking the appropriate response as accepted solution and helpful.

@Peter Bodelier Can you please share some screenshots regarding that. It must help me to solve quick. Thanks