Home > Database > Mysql Tutorial > body text

How to use MySQL fixed point numbers

PHPz
Release: 2023-06-02 23:09:49
forward
696 people have browsed it

MySQL fixed-point number

Principle:

Store the integer part and decimal part separately

Syntax:

Decimal(M,D)

Note:

Decimal is variable length, roughly every 9 numbers are stored with 4 bytes, integers and decimals are calculated separately, the maximum M is 65, the maximum D is 30, the default is ( 10,2)

Fixed-point numbers and floating-point numbers support unsigned and display width 0 padding.

The above is the detailed content of How to use MySQL fixed point numbers. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:yisu.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template