By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,102 Members | 967 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,102 IT Pros & Developers. It's quick & easy.

Getting the first letter of a field

P: n/a
How can I retrieve the first letter of data in a field within access?
(using access 2k?) is this a VB thing or is there an obvious solution?
Nov 12 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
in a Query use this - Left([yourfieldname],1)

HTH
David B
George Thompson <do**********@hotmail.com> wrote in message
news:c5*************************@posting.google.co m...
How can I retrieve the first letter of data in a field within access?
(using access 2k?) is this a VB thing or is there an obvious solution?


Nov 12 '05 #2

P: n/a
George Thompson wrote:
How can I retrieve the first letter of data in a field within access?
(using access 2k?) is this a VB thing or is there an obvious solution?

FirstChar=Left(SomeField,1)

--
Ronald W. Roberts
Roberts Communication
rw*******************@robcom.com
To reply remove "_at_robcom_dot_com"

Nov 12 '05 #3

P: n/a
Another way, as the search criteria, is to let the query perform a paremeter
search...

[Question]*.*

Replace 'Question' with a user prompt, such as "Which letter do you want to
search for?".

The query then searches for this letter and appends it to the wildcard *.*.

E.g. Entering L in surname field will result in all surnames beginning in L
being listed.
"George Thompson" <do**********@hotmail.com> wrote in message
news:c5*************************@posting.google.co m...
How can I retrieve the first letter of data in a field within access?
(using access 2k?) is this a VB thing or is there an obvious solution?

Nov 12 '05 #4

P: n/a
George Thompson previously wrote:
How can I retrieve the first letter of data in a field within access?
(using access 2k?) is this a VB thing or is there an obvious solution?


Assuming you mean the leftmost character (whether a letter or a number)
then you can use a function
Left(myfieldname,1)

Peter Russell
Nov 12 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.