Full Version: formating data in a query
UtterAccess Discussion Forums > Microsoft® Access > Access Queries
jimmyp
I need to combine two fields with a query and format the number of decimal places in the new field. I have one field which is a "1" and I need to format as "001" and another which is a counter field and needs to be formatted like "00001". Then I need to join both fields in to one where it is shown as "001-00001". I am new to this and need all the help I can get and thank you in advance for taking the time.

JimmyP
freakazeud
Hi,
I'm not exactly sure why you need to do that but you can probably use the format function for this e.g.:

YourNewCombinedField: Format([FirstOtherField],"000") & "-" & Format([SecOtherField],"00000")

HTH
Good luck
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.