Solved

Number with a decimal

Posted on 2011-02-22
9
281 Views
Last Modified: 2012-05-11
I feel like a fool for asking this... but I have a field in a form and everytime I hit, 4.5 it comes up as "4"... how do I make it so it stays the same? I have checked everything I can think of.

Attached is the database. The fields are "Total Hours" and "Duration"... please explain so I can fix it in the future.

Thanks!

Chris
0
Comment
Question by:cansevin
9 Comments
 

Author Comment

by:cansevin
ID: 34955353
0
 
LVL 75

Accepted Solution

by:
DatabaseMX (Joe Anderson - Access MVP) earned 500 total points
ID: 34955387
In the Bookings table ... change the Field Size of Total Hours from Long Integer to Single.

mx
0
 
LVL 119

Expert Comment

by:Rey Obrero
ID: 34955394
change the Field size to double
0
 
LVL 75
ID: 34955399
Oh ... and same for Duration in the Appointments table.

mx
0
Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

 
LVL 75
ID: 34955421
see image
Capture1.gif
0
 
LVL 119

Expert Comment

by:Rey Obrero
ID: 34955439
see this


PracticeMdb.mdb
0
 
LVL 75
ID: 34955441
attached with fix.

mx
PracticeMdb-MX01.zip
0
 
LVL 21
ID: 34955756
Unless you need more than 4 decimal places I find that the Currency data type is actually better and more accurate  in precision than single or double.
0
 
LVL 75
ID: 34955874
Since the OP is apparently dealing with Hours, Single with two decimal places is more than sufficient,  having a decimal precision of 7 places.

Both Double and Currency take up 8 bytes to store, whereas Single takes only 4 bytes.

mx
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

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…
Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.

757 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

21 Experts available now in Live!

Get 1:1 Help Now