Solved

How to display just last name?

Posted on 2013-01-28
4
363 Views
Last Modified: 2013-12-18
Experts,

I need to display just the last name of an author...how?  Would likely be the first name before the / in the Company Name:

John Smith/Marketing/Company
0
Comment
Question by:AliciaVee
4 Comments
 
LVL 38

Expert Comment

by:Rich Rumble
ID: 38829686
If you have the Surname/Lastname filled in for your users details then you can query it in a variety of ways. It seems like you want to do it for Lotus Notes? Your Subject and Question are a bit light on details.
The "SN" field of AD is the typical place to find a lastname.

dsquery * dc=some,dc=company,dc=com -filter "(sAMAccountName=user_x)" -attr sn

In windows, if you have dsquery installed/enabled, you would query against some.company.com for user_x and his/her "SN" attribute. Lotus seems to be very similar using Ldap queries, I found this
ldapsearch -h ldap.acme.com "objectClass=*" mail cn sn givenname
http://publib.boulder.ibm.com/infocenter/domhelp/v8r0/index.jsp?topic=%2Fcom.ibm.help.domino.admin.doc%2FDOC%2FH_EXAMPLES_EXPORTING_THE_CONTENTS_OF_AN_LDAP_DIRECTORY_2804_STEPS.html
I hope that helps you.
-rich
0
 
LVL 13

Expert Comment

by:CRAK
ID: 38830693
If your addressbook is filled out properly and you already have an abbreviated or canonical name, you may want to look into (formula) @NameLookup, (Lotusscript) notesDirectory.LookupNames or (java) lookupNames.
Designer help will provide you with the required parameters.
0
 
LVL 4

Accepted Solution

by:
QuinF earned 500 total points
ID: 38830865
Server := "yourservername/yourdomain";
Database := "yourcompanyaddressbook.nsf";
@DbLookup("":"NoCache"; Server : Database ; "($Users)"; @username ; "LastName")

This formula uses the ($Users) view in the company address book.  It takes the user's username and retrieves the Last Name field.  

Hope this helps,
Quin
0
 

Author Closing Comment

by:AliciaVee
ID: 38832244
Thanks!  This worked great!!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
Lack of Storage capacity is a common problem that exists in every field of life. Here we are taking the case of Lotus Notes Emails, as we all know that we are totally depend on e-communication i.e. Emails. This article is fully dedicated to resolvin…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.
Need to grow your business through quality cloud solutions? With everything required to build a cloud platform and solution, you may feel like the distance between you and the cloud is quite long. Help is here. Spend some time learning about the Con…

914 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now