Hello

I have an exam tommorrow and my question is :

What is the difference between the types of the data base text and number in the data base. My teacher tells us that a phone number is in the text column because it does not change. But in number it's changble ?

What is the difference between these two and can someone please give me an example for text and number and which one can change

thankyou

Someone will correct me if I'm wrong, but here's what I think your teacher is referring to.

The numbers that you do not want to be automatically sequential or change by means of a formula in any way are text.

The numbers you want to be automatically sequential (such as numbering down the left side of a page) or change by means of a formula (totals or quotients or ??) are the changeable ones. That is, they can be set to change automatically.

Here are three articles regarding the uses of numbers in Microsoft's database, Access:

-------------------
• How to reset an AutoNumber field value in Access
(812718) - Set the AutoNumber field of the main table to a Number data type. ... Create a new field of Number data type in the referenced table. ... For additional information, click the following article number to view ...
http://support.microsoft.com/kb/812718/en-us

• How to store, calculate, and compare Date/Time data in Microsoft Access
(210276) - Store Date/Time data Access stores the Date/Time data type as a double-precision, floating-point number up to 15 decimal places. The integer part of the double-precision number represents the date. ... Access stores dates before December 30, 1899 as negative numbers.
http://support.microsoft.com/kb/210276/en-us

• Functions for calculating and for displaying Date/Time values in Access
(210604) - Because a Date/Time value is stored as a double-precision number, you may receive incorrect formatting results when you try to manipulate Date/Time values in an expression. ... Because a Date/Time value is stored as a double-precision number, you may ...
http://support.microsoft.com/kb/210604/en-us

------------------------

=)

When it comes to databases, the difference between the text and number data types is how the data is stored and manipulated.

Text data type is used for storing alphanumeric characters, such as names, addresses, or descriptions. It can include letters, numbers, symbols, and spaces. Text data is typically used when the value does not need to be used in calculations or mathematical operations. For example, a person's name or an address can be stored as text because they are not typically used for calculations.

On the other hand, the number data type is used for storing numeric values that can be used in mathematical operations. This could include integers (whole numbers) or decimals (fractions). Numbers can be used for calculations such as addition, subtraction, multiplication, or division. For example, if you need to calculate the total sales of a product, you would use a number data type to store the sales values.

In your teacher's example, a phone number is stored as text because it is not typically used in mathematical operations. The phone number remains the same and does not require any calculations. However, if you were to store a numerical value that changes, such as the price of a product, you would use a number data type. The price can change over time, and you may need to perform calculations on it, such as applying discounts or calculating the total cost.

To determine whether to use the text or number data type in a database, you should consider the nature of the data and how it will be used. If the data is alphanumeric and not used in calculations, text is appropriate. If the data is a numeric value that will be used in calculations, a number data type should be used.

Remember that the specific implementation of text and number data types may vary depending on the database management system you are using. It is always a good idea to consult the documentation or resources specific to your database system for more information on data types and their usage.