Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2006
    Posts
    3

    Unanswered: Error Using memo Field for calculations

    Hi

    I have used the left function to extract part of a memo field which has been was fine. Not all of the fields have the numbers which need to be extracted. The problem is that when I have try and perform calculation with the new field for the cells which dont contain a number it displays error. Please can you let me know how I can get around this problem.

    Any help is appreciated

    Thank you

  2. #2
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    Code:
    ...iif(LEFT(memo_col, 3) LIKE "*[!0-9]*", 0, LEFT(memo_col, 3) + 2)
    Testimonial:
    pootle flump
    ur codings are working excelent.

  3. #3
    Join Date
    Jul 2007
    Posts
    16
    Hi

    I am now having a problem as the following code does not work
    Last edited by Weebot; 03-21-09 at 14:39.

  4. #4
    Join Date
    Jul 2007
    Posts
    16
    Hi

    I have tried to implement what you have recommended but now have the follwoing problem

    HPAS: IIf(Left([Product],InStr(1,[Product]," mSpec Tp")-1) Like "*[ !1-24]*", 0,(Left([Product],InStr(1,[Product]," mSpec Tp")-1)))

    Please can someone let me know why this does not work. And still displays errors for the string which do not have the data instead of "0"

  5. #5
    Join Date
    Jun 2005
    Location
    Richmond, Virginia USA
    Posts
    2,763
    Provided Answers: 19
    The simple fact of the matter is that memo fields should only be for...memos! In other words for notes. They never be used for data that in any way,shape or form will ever need to be manipulated. IF you follow this simple concept, you be fine. If you don't, you will almost always run into problems. Data that you will need to manipulate should always be stored in discrete fields.
    Hope this helps!

    The problem with making anything foolproof...is that fools are so darn ingenious!

    All posts/responses based on Access 2003/2007

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •