Field appearing as text field in access query

Posted on 2011-04-25
Last Modified: 2012-05-11
I have a Select query that returns a value based on an IIF and DLookup statement.  I am looking up a number in another table, based on a number falling between 2 numbers.  However, the query returns a text field, and even if I format it as a number via Field Properties, it is still seen as a number when I sort the column or download the data to excel. It also doesn't allow me to select the number of decimal places.  Any ideas?
Question by:GIStewart
    LVL 13

    Accepted Solution

    Typecast your field to either:


    Look up typecasting in help for more information.

    Author Comment

    Thank you.  Val(fieldname) worked just as I was hoping

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Threat Intelligence Starter Resources

    Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

    Suggested Solutions

    I originally created this report in Crystal Reports 2008 where there is an option to underlay sections. I initially came across the problem in Access Reports where I was unable to run my border lines down through the entire page as I was using the P…
    We were having a lot of "Heartbeat Alerts" in our SCOM environment, now "Heartbeat" in a SCOM environment for those of you who might not be familiar with SCOM is a packet of data sent from the agent to the management server on a regular basis, basic…
    In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
    The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…

    794 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now