Preserve Data using script during a clone
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-03-2025 10:12 PM
Hi Team,
Have anyone come across scenarios where you want to preserve data on a table during a clone, depending on the data on another table.
For example, I need to preserve the user roles for members of a group. For this I will need to do a query on the sys_user_grmember table first to get the users and then preserve their roles in the sys_user_has_role table.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-07-2025 11:58 AM
Hi @daisybora ,
You want to preserve user roles assigned to users who belong to a specific group during a clone operation, but this data exists across two tables:
sys_user_grmember (maps users to groups)
sys_user_has_role (maps users to roles)
During a clone, this data could be lost or overwritten, especially if data preservation rules are not explicitly defined for both tables.
Let me know if u need steps .
If this solution helps you then, mark it as accepted solution ✔️ and give thumbs up 👍 !
Regards,
Pratik