Solved

How to set Format and decimal places using ALTER TABLE

Posted on 2014-03-01
2
409 Views
Last Modified: 2014-03-02
Can anyone help with the ALTER TABLE statement to change a fieldsize Long Integer to Fixed Format 2 decimal places.

Thanks in advance.
0
Comment
Question by:CRB1609
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 37

Accepted Solution

by:
PatHartman earned 500 total points
ID: 39898154
That is not possible.  Integers are whole numbers.  If you want decimal positions, you need to use a data type that supports them.  The most user-friendly choice is Currency which works as long as you only need four decimal places.  Don't confuse the Currency data type with the Currency format.  The Currency data type can be formatted however you want.

Also, formatting doesn't affect how data is stored.  It only affects how data is displayed.  Formatting is for humans.
0
 

Author Closing Comment

by:CRB1609
ID: 39898279
Thanks very much.  I never did understand the difference.  Now I do.
0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

740 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