Numeric Type Attributes
【Numeric Type Attributes】
INT(4)
specifies an INT
with a display width of four digits.
This optional display width may be used by applications to display integer values having a width less than the width specified for the column by left-padding them with spaces. (That is, this width is present in the metadata returned with result sets. Whether it is used or not is up to the application.)
主要是起补0作用。
The display width does not constrain the range of values that can be stored in the column. Nor does it prevent values wider than the column display width from being displayed correctly. For example, a column specified as SMALLINT(3)
has the usual SMALLINT
range of -32768
to32767
, and values outside the range permitted by three digits are displayed in full using more than three digits.
数字位数超过时,正常存储。
When used in conjunction with the optional (nonstandard) attribute ZEROFILL
, the default padding of spaces is replaced with zeros. For example, for a column declared as INT(4) ZEROFILL
, a value of 5
is retrieved as 0005
.
参考:https://dev.mysql.com/doc/refman/5.7/en/numeric-type-attributes.html
Numeric Type Attributes的更多相关文章
- int 4 bytes
http://waynewhitty.ie/blog-post.php?id=19 MySQL - INT(11) vs BIGINT(11) vs TINYINT(11) This seems to ...
- mysql 创建数据库知识总结
表设计 库名.表名.字段名必须使用小写字母,"_"分割,且名称长度不超过12个字符并且要做到见名知意. 建议使用InnoDB存储引擎. 存储精确浮点数必须使用DECIMAL替代FL ...
- 5.24 Declaring Attributes of Functions【转】
转自:https://gcc.gnu.org/onlinedocs/gcc-4.0.0/gcc/Function-Attributes.html 5.24 Declaring Attributes o ...
- [翻译]The Neophyte's Guide to Scala Part 12: Type Classes
The Neophyte's Guide to Scala Part 12: Type Classes 过去的两周我们讨论了一些使我们保持DRY和灵活性的函数式编程技术,特别是函数组合,partial ...
- Standard Numeric Format Strings
The following table describes the standard numeric format specifiers and displays sample output prod ...
- Android Lint Checks
Android Lint Checks Here are the current list of checks that lint performs as of Android Studio 2.3 ...
- Python2.7.6标准库内建函数
Built-in Functions abs() divmod() input() open() staticmethod() all() enumerate() int() ord( ...
- System Error Codes
很明显,以下的文字来自微软MSDN 链接http://msdn.microsoft.com/en-us/library/windows/desktop/ms681382(v=vs.85).aspx M ...
- __attribute__
转来的: http://www.cnblogs.com/astwish/p/3460618.html __attribute__ 你知多少? GNU C 的一大特色就是__attribute__ 机制 ...
随机推荐
- tornado-模版reverse_url
from tornado.web import url handler=[ url(r"/hello", grab_handler.HelloHandler, name='hell ...
- 调试kettle插件
http://wiki.pentaho.com/display/EAI/How+to+debug+a+Kettle+4+plugin
- sqlserver 导入导出
待写 excel 导入 数字日期等导入为文本,在excel设置类型为文本再导入即可. Excel数字.文本混合列导入SQL Server出现的问题&解决办法 Excel文件: 序号 姓名 内部 ...
- python3封装Api接口
注:本篇的代码和语法基于Python3.5环境,下面将用到Python 的Flask框架 封装接口主要讲静态接口(无参数传入).动态接口(有参数传入,不同参数返回的信息不同).针对动态接口有三种传参方 ...
- py库: jieba (中文词频统计) 、collections (字频统计)、WordCloud (词云)
先来个最简单的: # 查找列表中出现次数最多的值 ls = [1, 2, 3, 4, 5, 6, 1, 2, 1, 2, 1, 1] ls = ["呵呵", "呵呵&qu ...
- cookie操作:设置cookie、读取cookie、删除cookie
一.设置cookie function setCookie(name, value){ Days = 1; var exp = new Date(); exp.setTime(exp.getTime( ...
- hdoj 1004 学习思路
hdoj 1004题目大概讲的是,将输入的字符串根据输入次数多少,输出出现次数最多的字符串. 题目逻辑很简单,就是需要选择相应的数据结构,看了别人提交的discuss,明显发现可以使用多种数据结构解这 ...
- Delphi与各数据库数据类型比较
Delphi数据类型与各数据库数据类型对比如下表,如有具体说明见表中脚注: Delphi Type Oracle Types SQL Server Types MySQL Types [1] Inte ...
- 在WINDOWS上开发IOS应用的方法
1,虚拟机上安装MAC系统,里面装XCODE 2,WINDOWS上安装code blocks,这个IDE可以直接在WIN上编译XCODE工程: 最新的IOS在windows环境下编译环境搭建记录
- openwrt手动wifi设成client模式[笔记]
说明:刚刷好的OPENWRT,默认是不带luci-web管理的,所以得手工SSH或TELNET上去改WIFI模式,以便通过WIFI连到现有的ROUTER去下载安装luci...: root@OpenW ...