Forum Discussion
Pawel
New Contributor II
It turned out it is not possible by an export/import but there is a way by stepping in the application database.
''' query to delete specific TR Group from TR Profiles
Dim trGroupName As String = "FW_1000_COMMON"
Dim trProfName As String = "___/_TB/_LOAD"
Dim querry As String = $"
delete rpm
from StageRuleProfiles rp
join StageRuleProfileMembers rpm on rpm.[RuleProfileKey] = rp.[UniqueID]
join StageRuleGroups rg on rpm.[RuleGroupKey] = rg.[UniqueID]
where 1=1
and rp.[RuleProfileName] like '{trProfName}' escape '/'
and rg.[RuleGroupName] = '{trGroupName}'
"
'Return the DataTable
Using dbConnApp As DBConnInfo = BRAPi.Database.CreateApplicationDbConnInfo(si)
Return BRAPi.Database.ExecuteSql(dbConnApp, querry, False)
End Using
KarlT
4 months agoContributor III
I personally would avoid this type of SQL manipulation.
I'd be interested to understand the use case that requires this automation of changing the group assigned to the profile?
Related Content
- 11 months ago
- 11 months ago