Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 2009
    Posts
    85

    Unanswered: strip zero's of of 8000 records

    I just got a crystal report with customer information the zip code field is given as
    554090000
    612890000 ect
    dose some one have advice on how to strip off those zero's, thanks

  2. #2
    Join Date
    Jun 2007
    Location
    Maitland NSW,Australia
    Posts
    388
    Using 554090000 if you need to strip the zeroes to give 55409 then use an update query to update the field

    If the field is numeric use [field name]/10000

    If the field is text then use Val([field name])/10000

    Remember to backup the data before you update.

  3. #3
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    I might suggest Left$([field], 5) on the text tip.
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  4. #4
    Join Date
    Apr 2009
    Posts
    85
    Wow of course, divided by 10000, I feel completely stupid. I have not yet used the Left$() function, I will try, just to use something new. Thank you both

  5. #5
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    I'd go with the divide by 10,000 idea
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

Posting Permissions

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