Results 1 to 6 of 6
  1. #1
    Hswift is offline Novice
    Windows 8 Access 2013
    Join Date
    Dec 2015
    Posts
    20

    Getting zeros to remain in a numbers column.

    Hello,

    I’m importing a column of numbers that appear like this in its original file

    numberscolumn


    167847651
    000000065
    000000646

    However, the column looks like this after I have imported it into Access

    numberscolumn
    16784765
    65
    646

    How can I get the zeros to remain in Access like they do in the original file?

    Thanks!

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,772
    Are you importing to an existing table? Is the field set up as text type?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    Hswift is offline Novice
    Windows 8 Access 2013
    Join Date
    Dec 2015
    Posts
    20
    I am not importing to an existing table. I can setup the field to be anything you think is best.

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,772
    It must be text type to retain the zeros. Otherwise, will have use a calculation in query or textbox to force display of leading zeros.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    Hswift is offline Novice
    Windows 8 Access 2013
    Join Date
    Dec 2015
    Posts
    20
    Thanks! that fixed it.

  6. #6
    CJ_London is online now VIP
    Windows 8 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,938
    or just format the numeric value

    format(myNumber,"000000000")

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

Similar Threads

  1. sum up the positive numbers in a column
    By megatronixs in forum Queries
    Replies: 4
    Last Post: 11-21-2015, 02:05 AM
  2. Replies: 3
    Last Post: 10-30-2014, 08:45 AM
  3. Calcuate How many days remain in sharepoint
    By sdc1234 in forum SharePoint
    Replies: 2
    Last Post: 10-01-2014, 05:51 AM
  4. How to total a column of numbers in a subform?
    By snowboarder234 in forum Forms
    Replies: 3
    Last Post: 04-24-2012, 09:39 AM
  5. Remain on Current Record
    By billgyrotech in forum Forms
    Replies: 17
    Last Post: 08-08-2011, 12:15 PM

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