dbenjamin Super Contributor.
Super Contributor.
677 views

Delimited Text driver, delete a single group from a user.

Delimited Text Base 2.3.2.201806

Background:
I have students dumped from our Student Information System (SIS) to a csv file. I parse the file and create the accounts and set default passwords. One of the groups is based on their birthday, for compliance students under 13 years of age have a different internet requirement than those over 13.

Creation:
The csv is parsed and the students are placed in the correct groups one of which is either Under13 or Over13, this works as expected.

The Modify Problem:
As a student ages they need to be moved from the Under13 to Over13 group. I can add the Over13 group to the existing groups, what I have not found is an easy way to remove the Under13 group when they are added to the Over13 group.

What is the best way to do this? Use a node set? Always delete the Under13 group and put it back if needed? I'm sure there are several things I have not thought of as I am new to IDM.

Thanks for your help,
David.
Labels (1)
0 Likes
5 Replies
Knowledge Partner
Knowledge Partner

Re: Delimited Text driver, delete a single group from a user.

On 09/19/2018 10:34 AM, dbenjamin wrote:
>
> Delimited Text Base 2.3.2.201806
>
> Background:
> I have students dumped from our Student Information System (SIS) to a
> csv file. I parse the file and create the accounts and set default
> passwords. One of the groups is based on their birthday, for compliance
> students under 13 years of age have a different internet requirement
> than those over 13.


I presume the group is not in SIS, but is something you make up as part of
your business logic. As a result, I do not think you should do this, at
all, in this driver config since it is not something that really deals
with synchronization from SIS, but is a function of something else (age of
students, and time passing). Whether or not this is deal or not is
debatable, and you already have it working, so for now let's move on.

> Creation:
> The csv is parsed and the students are placed in the correct groups one
> of which is either Under13 or Over13, this works as expected.
>
> The Modify Problem:
> As a student ages they need to be moved from the Under13 to Over13
> group. I can add the Over13 group to the existing groups, what I have
> not found is an easy way to remove the Under13 group when they are added
> to the Over13 group.


If you have a Null driver config that watches for the change that you
already have working, which adds Over13 group memberships to users, you
could easily have it check for Under13 and, if present, remove it. Easy
peasy, and without much modification in general.

--
Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below.

If you want to send me a private message, please let me know in the
forum as I do not use the web interface often.
dbenjamin Super Contributor.
Super Contributor.

Re: Delimited Text driver, delete a single group from a user

Thanks for the guidance. It makes perfect sense when you say it!
0 Likes
Knowledge Partner
Knowledge Partner

Re: Delimited Text driver, delete a single group from a user.

On 9/19/2018 3:24 PM, dbenjamin wrote:
>
> Thanks for the guidance. It makes perfect sense when you say it!


On the list of "Things rarely said to/about Aaron."

His point of dividing biz logic into one place, and API/transport into
another is a good one that many people miss out on.

0 Likes
Knowledge Partner
Knowledge Partner

Re: Delimited Text driver, delete a single group from a user

dbenjamin;2487790 wrote:
Delimited Text Base 2.3.2.201806

Background:
I have students dumped from our Student Information System (SIS) to a csv file. I parse the file and create the accounts and set default passwords. One of the groups is based on their birthday, for compliance students under 13 years of age have a different internet requirement than those over 13.

Creation:
The csv is parsed and the students are placed in the correct groups one of which is either Under13 or Over13, this works as expected.

The Modify Problem:
As a student ages they need to be moved from the Under13 to Over13 group. I can add the Over13 group to the existing groups, what I have not found is an easy way to remove the Under13 group when they are added to the Over13 group.

What is the best way to do this? Use a node set? Always delete the Under13 group and put it back if needed? I'm sure there are several things I have not thought of as I am new to IDM.

Thanks for your help,
David.


When your logic indicates you should add them to the Over13 group, which you've already worked out, remove them from the Under13 group.

If there's a chance that they're not actually in the Under13 group, you could check first to see if the remove is needed. An if-dest-attr Group Membership equals {the DN to your Under13 group} would do it.
0 Likes
Knowledge Partner
Knowledge Partner

Re: Delimited Text driver, delete a single group from a user.

> If there's a chance that they're not actually in the Under13 group, you
> could check first to see if the remove is needed. An if-dest-attr Group
> Membership equals {the DN to your Under13 group} would do it.


One neat thing about how IDM handles nodesets and conditions is that if
you build the DN in the same format as the query returns (Which is me
reminding you to ensure the \TREE\ value is there) then you can test if
the values (nodeset) equals one value, and if it matches ANY it is true,
and if not false.

So you can do a Source/Dest Attr of Member from the Group, into a
nodeset variable, then simply test if the NODESET equals the value of
your user or group or whatever.

Remember to do user's Group Membership, Security Equals, and the Group's
Member and Equivalent To Me attributes.

(Or if you let the engine do it through recipricol attributes, remember
to do both the member linkage and the security linkage halves).


0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.