Results 1 to 9 of 9
  1. #1
    sergran is offline Competent Performer
    Windows 7 64bit Access 2007
    Join Date
    Jun 2013
    Posts
    115

    Tolleranza numerica


    Hi, I need your help, if possible. I would have on my form that I use for data entry can provide values such as -20 and get 100 + as a result 90-110 In practice in addition to the calculation should also get a reduction in the range. In fact the correct value would be 80-120
    Thank you

  2. #2
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    I don't understand your question. You want to put in two values, tolerance and some sort of maximum value (in your example 20 and 100) and you want to display a tolerance range of 80 - 120 as a text value?

    if so it would be something like

    ToleranceRange: MaxValue - range & "-" & Maxvalue + range

    in a query

  3. #3
    sergran is offline Competent Performer
    Windows 7 64bit Access 2007
    Join Date
    Jun 2013
    Posts
    115
    Hi, in practice the digitazioen of a value in a field eg. 100 + -20 the result should be 90-110. In practice should be calculated and then reduce by 10 the range

    Sorry but I tried to put in a query the recommended formula but gives me an error.
    Could you send me a sample of alelgato a query? Thanks 1000

    P.s. sorry but no practical

  4. #4
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    You have to modify the field names with whatever you're using.

    MaxValue in my example is your 100
    Range is your 20.

    you have to substitute your actual field names to get it to work. if your tolerance is +/- 20 it means 20 below your value or 20 above your value
    if you want a range of 90 - 100 your tolerance is 10, not 20.
    I don't know of any tolerance value that is half of the stated (I've never seen it done) but if you are really recording your tolerance as double what it should be, just halve the value in your formula (divide the range by 2)

  5. #5
    sergran is offline Competent Performer
    Windows 7 64bit Access 2007
    Join Date
    Jun 2013
    Posts
    115
    forgive me but I just can't ... in practice 100 + -20 is part of the same field ... I tried to change the name of the field but did not find the same. In fact I would serve as you wrote you that if I write + -20 I need that is reduced by 10.
    E.g. If we assume there is written 140 + -30 the result should be 120-160. In practice the tolerance value to remove a 10
    Thank you

  6. #6
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    I see

    to get the 'max' value you'd use the left function
    to get the 'range' value you'd use the right function

    so

    trim(left([tolerance], instr(tolerance, " ")))

    should give you 100 if there is always a space before your + sign

    if not you'd probably have to use something like

    trim(left([tolerance], instr([tolerance], "+"))

    similarly your range would be something like

    trim(right([tolerance], instr([tolerance], "-" + 1, len([tolerance]) - instr([tolerance], "-") + 1)) - 10

    so your lower bound would be something like:


    trim(left([tolerance], instr([tolerance], "+")) - (trim(right([tolerance], instr([tolerance], "-" + 1, len([tolerance]) - instr([tolerance], "-") + 1)) - 10)

  7. #7
    sergran is offline Competent Performer
    Windows 7 64bit Access 2007
    Join Date
    Jun 2013
    Posts
    115
    OK thank you ...sorry but I have to put it in where he queries the function? I put in "pattern" but it doesn't work. Surely I plug it in the wrong place. It tells me "syntax error"

  8. #8
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    did you try to get the smaller parts working rather than trying to just cut and paste my formula? work on the smaller parts first, make sure you get a result you're expecting, then move on to the next part, once you are able to correctly get the smaller parts then combine them into the bigger formula.

  9. #9
    sergran is offline Competent Performer
    Windows 7 64bit Access 2007
    Join Date
    Jun 2013
    Posts
    115


    but it keeps giving me the same error ... sigh sigh
    You don't want to break but just can't seem

Please reply to this thread with any new information or opinions.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums