UMRA - Name Generation With Inline Loop
June 14th, 2010 / 1 feedback » / by admin
(UMRA) - User Management Resource Administrator: Download || More Information
(ESSOM) - Enterprise Single Sign-On Manager: Download || More Information
(SSRPM) - Self Service Reset Password Management: Download || More Information
Other Solutions
I've had a few clients ask me lately a quick an easy way to use the UMRA Name Generation action outside of the UMRA Create User action. Now, some of you might be asking why, would someone want to do something like this... it's simple, with the More Information Create User action, your already starting the Create User Active Directory action, and it only checks Active Directory for this username. Maybe, you want to check another system, or make sure you never use a username that you've already used in Active Directory before. If you needed to check if you've ever used the generated username before, and you were using the naming generator within the More Information Create User action, it would not check any other system then Active Directory. Now, for some of you this might be perfectly fine, however, for those of you that fall within this workflow process, then this blog post is for you.
Below is a screen show of how to use the UMRA "Generate UserName" action.
So what’s is going on here? Let me explain...
Generate UserName: - This is what generates your username, this is exactly the same as the UMRA Create User Generate Username method, but it wont create the user at the same time.
Check UserName Database - This action will connect to your "source" where you keep your usernames that have already been in use, or even you can check a downstream application. For Example, you can check your HR system, or SIS to see if this username is already in use, and might not yet be in Active Directory.
Get Database Query Rows - After your search of your "source" system, you can now check how many rows were returned from your query.
Check DB Row Count - Now this is the most key action of all the UMRA actions we in this script. What this will do is check the variable you set to hold the Database Row Count. Now if your row count = 0, then we go to "Create User" since we know the username has not yet been used. If the row count =< 1 , you need to go back to "Generate UserName", and thus start the whole process over again.
Create User - If your IF/THEN/ELSE = false then we can create the user account in Active Directory since we know the username is not used / found in your previous Database Query.
Update UserName Database - This action might not be something you would use, however assuming you have some sort of database that hold all the usernames you've used, you would then update that database with the new username that was generated.
So there you have it, a quick and easy way to use the UMRA "Generate UserName" action with an inline loop. Now keep in mind, you can use this "inline loop" method on most of your scripts, however it does make your script less "reusable" since this logic will be contained only in a larger script. Anyways, like always feel free to post comments, or send me a message if you have any questions. 1> 1>
1 comment
This post has 52 feedbacks awaiting moderation...

