cancel
Showing results for 
Search instead for 
Did you mean: 

Portal Account List Problem

Former Member
0 Kudos

I am having an issue getting the portal username for all the available portal accounts. We are using LDAP for our UME Store.

First of all, I obtain the portal user list via UMFactory:

IUserFactory uf = UMFactory.getUserFactory();
    try {
	    ISearchResult ids = uf.getUniqueIDs();
	    while (ids.hasNext()) {
		    String uid = (String) ids.next();
		    IUser sapUser = uf.getUser(uid);
                                    IUserAccount sapUserAccount = sapUser.getUserAccounts()[0];
                                    .....
	    }
    }
    catch(Exception ex) {
	    wdComponentAPI.getMessageManager().reportException(new WDNonFatalException(ex), true);
    }

The problem is that all the following return something that is NOT a username that would be used to login, but rather what looks like it might be an LDAP account id number:

sapUserAccount.getLogonUid();
sapUser.getUniqueName();
sapUser.getName();

When I look at User Administration on the Portal Admin, I see the same list that I get back from the UMFactory (as expected).

My question is how can I get the username the user would log in as so I can display it in my list?

If the user logs into the portal and I grab the current user I get the username when calling the above methods. Any help available?

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

As a follow-up, let's say I have 1 portal user established in UME and 1 that is linked through LDAP. Portal user is

username Fred, LDAP user is username Barney.

When I go into User Administration and select the UME as the datasource I see the one portal user with Logon ID as Fred. When I set LDAP as the datasource I see one user with Logon ID as Barney. So far so good.

When I get the user list from UMFactory (using the method I posted above) I get two users, one with logon id of Fred (portal users show up fine) and one with logon id of 23C48754N$ (all LDAP user accounts show up with these odd ids).

What I need is to get a userlist that has two users, one with username of Fred and one with username of Barney.

Any help would be GREATLY appreciated.