BusinessObjects Board

Bulk delete of user accounts

Hi all

I know it is possible to perform a bulk upload of users into the cms but is anyone aware of a utility that would allow us to perform a bulk delete?

Cheers, Sandi


SandiR :uk: (BOB member since 2004-12-20)

I don’t think that there is a tool like that, but you can script it yourself.

Search the documentation of the SDK.


martensnl :netherlands: (BOB member since 2006-12-19)

I just uploaded a utility I wrote that’ll do bulk user deletes. It’s in BOB’s Uploads right now.

Joe


joepeters :us: (BOB member since 2002-08-29)

Hi Sandi & Joe,

I request both of you to give me the details of the scripts for bulk creation and deletion of users.

Thanks & regards,
Rajesh


rajeshmasapu (BOB member since 2007-06-24)

Here.


joepeters :us: (BOB member since 2002-08-29)

Many thanks Joe,

Do you have any utility which can be used for bulk creation of users?

Once again thanks in advance.

Regards,
Rajesh


rajeshmasapu (BOB member since 2007-06-24)

You can use the Import Wizard – see this recent thread for a discussion.

Joe


joepeters :us: (BOB member since 2002-08-29)

For bulk creation you can use the import wizard …

Just to bring this topic back on track as it seems to have morphed into a creation Q.

What I was (and still am :wink: ) asking is

Has anyone developed a utility to delete users from the CMS (using the sdk) but taking the usernames from a list supplied in an excel spreadsheet?


SandiR :uk: (BOB member since 2004-12-20)


joepeters :us: (BOB member since 2002-08-29)

Cheers Joe

I have looked at this already and although it goes someway towards what I want it is based on deleting users from a specified group (and the user itself if no longer a member of a group) and very well it works too!!! :slight_smile:

However - the list of users is being supplied to us from a source system extract to excel (and not from a BO extract).

The problem we have is that we have 2 BO reporting systems, the users use TSO to sign on to these systems from a source transactional system.

The customer can identify the users they require to remove - but only from the source system and can provide us with a list of names which need to be deleted from both BO systems.

Cheers, Sandi


SandiR :uk: (BOB member since 2004-12-20)

Oh!

If this is just a one-time job, you could do what I did recently:

  1. Create a temporary user group.
  2. Use a text file import in the Import Wizard to move your list of users into the temporary group.
  3. Use my Nuke-a-group utility to delete all the users that are in the temporary group.

For my purposes, after step 2 I re-ran the Import Wizard to take a BIAR file backup of the doomed user IDs.

If it’s an ongoing process and you really want to do it in one step in VBA, it should be pretty straightforward. As a quick example:

Dim c as Range
For Each c in range("a1:a10")
    oInfoStore.Query("select si_id from ci_systemobjects where si_kind = 'user' and si_name = ' " & c.Value & "'").Item(1).DeleteNow
Next

(note: I just wrote that code here, I haven’t tested it.)

Probably wouldn’t be a bad idea to add that functionality to my utility; I’ll add that to my to-do list :slight_smile:

Joe


joepeters :us: (BOB member since 2002-08-29)

Many many thanks Joe!

I have muted the usergroup approach when I first looked at your utility, but the system admins for the client did not want to go down that line unfortunately.

There will be an ongoing need for this user ‘housekeeping’ so the code you have documented will be invaluable.

I will have a go at creating a spreadsheet (VBA) in the next few days. :+1:


SandiR :uk: (BOB member since 2004-12-20)

OK - now I am maybe taking this a little too far now - but when a user is deleted I believe that some empty folders are left in the frs.
I remember some time ago someone mentioning a -prune param that may tidy these folders.

I have googled it to no avail - is anyone else aware of it and how to use it in a Excel/VB?


SandiR :uk: (BOB member since 2004-12-20)

Hi,

Maybe you are looking for this?


Marek Chladny :slovakia: (BOB member since 2003-11-27)

That’s brilliant - thanks Marek!


SandiR :uk: (BOB member since 2004-12-20)

When I try to run the nuke-a-group program I get “Unknown Action”. I just want to permananetly delete These users. They are not in any other group. The only option I see in the 2nd action column is “Remove users from group”. What should I be entering in each of the Action columns? Many thanks! for any info!


djoslyn (BOB member since 2011-01-17)

In XI3, the FRSs do a pretty good job of cleaning up after themselves.


joepeters :us: (BOB member since 2002-08-29)

Hi there is a slight problem with the Validation values (they are in Column J which is hidden). The data validation I think should be selecting Delete or Skip. Joe - can you confirm.
I had the same problem and just revised the validation cell selection after viewing the code. The macro code works brilliantly.

Cheers, Sandi


SandiR :uk: (BOB member since 2004-12-20)

Yep, you’re right. I just fixed that and posted an update in BOB’s Uploads.

Thanks!
Joe


joepeters :us: (BOB member since 2002-08-29)