how to capture the first letter of a in Microsoft Access? Please h

G

Guest

Dear all,

I already have a table. In this table, I have three columns for id,
firstName, LastName. How can I get three more columns for the FirstInitial,
LastInitial, and Initial? FirstInitial is the first letter of firstName,
LastInitial for the first letter for LastName, and Initial needs put the
LastInitial and FirstInitial together.

The records in my table look like:
id FirstName LastName
00021 Mary Smith
01234 John Atikins

The table I expect will look like:
id FirstName LastName FirstInitial LastInitial Initial
00021 Mary Smith M S SM
01234 John Atikins J A AJ


Can anybody help, Thanks,


Blinda








I
 
R

Roger Carlson

You don't need to actually store all of these. You can use the Left()
function to find these values anytime you want. For instance, in a query you
can put:
FirstInitial: Left(FirstName, 1)
LastInitial: Left(LastName,1)
Initial: Left(LastName,1) & Left(FirstName, 1)
each in its own field column.

--
--Roger Carlson
MS Access MVP
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L
 
G

Guest

Thank you so much, it works perfectly for me.

Roger Carlson said:
You don't need to actually store all of these. You can use the Left()
function to find these values anytime you want. For instance, in a query you
can put:
FirstInitial: Left(FirstName, 1)
LastInitial: Left(LastName,1)
Initial: Left(LastName,1) & Left(FirstName, 1)
each in its own field column.

--
--Roger Carlson
MS Access MVP
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L
 
D

dbahooker

the first letter of ANYTHING in Access is _F_ because MDB gets an F for
security, reliability and performance reasons
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top