Left function

C

Cheri Luoma

I am using Access 2007 and am new at this. I am trying to take a text field, a GL account number so it is numbers but exported as a text field into Access, and only show the first 6 digits on the left. I am using the formula Left([GL Account],6) and that formula is returning nothing. The same formula returns values if I am using it on a numeric field. Can anyone tell me what I am doing wrong. It seems so simple but it just is not working for me and I know if has to be related to the text field somehow.



EggHeadCafe - Software Developer Portal of Choice
XMLHelper Redux and IE WebBrowser in .NET
http://www.eggheadcafe.com/tutorial...7-b7cb36f41d1a/xmlhelper-redux-and-ie-we.aspx
 
J

Jeff Boyce

I can't tell from your description where you are trying to do this...

Regards

Jeff Boyce
Microsoft Access MVP

--
Disclaimer: This author may have received products and services mentioned
in this post. Mention and/or description of a product or service herein
does not constitute endorsement thereof.

Any code or pseudocode included in this post is offered "as is", with no
guarantee as to suitability.

You can thank the FTC of the USA for making this disclaimer
possible/necessary.
 
F

Fred

Is it possible that you have lots of leading blank spaces in the text field
and are returning those?
 
T

Terje M

Try $Left([GL Account],6) instead of just Left([GL Account],6)
Since its a alphanumeric field this should work better.

Terje M
 
J

John W. Vinson

On Mon, 23 Nov 2009 03:14:01 -0800, Terje M <Terje
Try $Left([GL Account],6) instead of just Left([GL Account],6)
Since its a alphanumeric field this should work better.

Correction: it's Left$ not $Left... and I very much doubt that using the
string function will make any difference.
 

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