Returns the string that a user enters as the login name when authenticating. The return value may be different from a Rational ClearQuest user name if the user is LDAP authenticated.
Use the GetUserLoginName method to get the Rational ClearQuest name of the user stored in the user profile record for the user.
Returns the login name used to create the Session. The value returned is the name used to authenticate the user, not the Rational ClearQuest user login field name that is stored in the user profile record for the user. The return value may be a LDAP login name (for example, myname@us.ibm.com) and not a Rational ClearQuest user name (for example, mycqname).
VBScript
session.GetAuthenticationLoginName
Perl
$session->GetAuthenticationLoginName();
VBScript
mySession.UserLogon "admin", "", dbName, AD_PRIVATE_SESSION, "" set mySession = CreateObject("ClearQuest.Session") mySession.UserLogon "admin", "", dbName, AD_PRIVATE_SESSION, "" userLogin = mySession.GetAuthenticationLoginName ' ...
Perl
use CQPerlExt; my ($login, $pwd, $dbname, $dbset, $cqusername) = @_; my $authusername = $login; my $sessionObj = CQSession::Build(); $sessionObj->UserLogon($login, $pwd, $dbname, $dbset); my $loginname = $sessionObj->GetUserLoginName(); my $authloginname = $sessionObj->GetAuthenticationLoginName(); print "User login: $authusername , $authloginname , $cqusername, $loginname \n"; if ($loginname ne $cqusername) { print "User login $loginname != $cqusername!!\n"; } if ($authloginname ne $authusername) { print "User authname $authloginname != $authusername!!\n"; } CQSession::Unbuild($sessionObj);