Ms Access – Percentage Field Formatting

A quick tip to fix what shouldn’t be a problem!

Occasionally, Access can act rather confusingly. I ran into a typical example early this morning, when I was trying to get Access to allow entry of percentages correctly. I’ve done this about one thousand times before and probably solved this problem one thousand times as well, but every time it happens it causes me to scratch my head (mostly in disbelief).

What happens is this: You set up a field in a table, designate it to be formatted as percentage. Right OK – you go to your form design, set up your input fields, and then try to enter a number as a percentage, and notice that it keeps rounding to 100% or 0%. Frustration ++.

Back to table design. The problem here is that you have to correctly set the field data type as well as the data type format. However, the data type is not integer, double, or even decimal – it is usually single. Once you set that on your percentage fields, you can enter data in decimal format (i.e. 0.5, 0.25 etc etc) and it will show up in its proper percent format.

I know this is shouldn’t be a problem but, amazingly, people get caught by it all the time, and there doesn’t seem to be clear answers on the web. Hopefully this tip does something to addressing this issue.

Post to Twitter Tweet This Post

This entry was posted in General. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

16 Comments

  1. Brett
    Posted September 6, 2007 at 6:06 pm | Permalink

    Thank you.

    You are a lifesaver. I have been pulling my hair out with this for two days!

  2. Posted September 10, 2007 at 11:11 am | Permalink

    Brett. No worries. Glad I could be of assistance.

  3. John
    Posted February 20, 2008 at 8:16 pm | Permalink

    Thank you!
    I was really stuck on this on, hit this site on a Google search and Bingo, quick, easy and simple solution.

    Thanks agein!

  4. Posted February 21, 2008 at 10:04 am | Permalink

    John – no worries! Glad to be of service.

  5. SimpleSimon
    Posted April 3, 2008 at 12:21 am | Permalink

    But what if I want to enter “2.5″ on the form and for it to be displayed as “2.5%” and stored as “2.5%” in the table?

  6. Posted April 3, 2008 at 2:36 am | Permalink

    From memory, it might depend on your access version. Newer versions have figured this out (that when you say 2.5 in a percentage field, you mean 2.5% and not 250%). You could simply set it to percentage.

  7. ww1flyingace
    Posted April 15, 2009 at 5:25 pm | Permalink

    Thank you so much for this information! Why are points like this not given to us in the help section? How hard would it be to add the line “When dealing with percents, be sure that your variable and field are set to ’single’.” :-)

  8. Posted May 11, 2009 at 11:29 pm | Permalink

    No worries ww1flyingace.

  9. trader joe
    Posted July 9, 2009 at 6:18 pm | Permalink

    “I know this is shouldn’t be a problem but, amazingly, people get caught by it all the time, and there doesn’t seem to be clear answers on the web. Hopefully this tip does something to addressing this issue.”

    So true. Thanks for the info.

  10. Debbie Dickinson
    Posted January 7, 2010 at 9:02 pm | Permalink

    THANK YOU! Couldn’t find this anywhere and was also getting frustrated!

  11. Posted January 12, 2010 at 4:11 am | Permalink

    Debbie, no worries. Thanks for stopping by.

  12. Posted January 30, 2010 at 11:17 am | Permalink

    Thank you – just saved me a lot of headscratching!!

  13. Posted February 1, 2010 at 3:09 am | Permalink

    No worries Stuart.

  14. Posted February 3, 2010 at 5:08 am | Permalink

    Thank you! That problem has been bugging me for days!

  15. Posted February 3, 2010 at 5:48 pm | Permalink

    Glad I could help Andres

  16. LMB
    Posted March 17, 2010 at 11:15 pm | Permalink

    Thank you – like you, I’ve fixed it before, but always forget to make the field single!

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>