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__ 机制 ...
随机推荐
- python零散补充与总结
一 有一种情况,在Windows系统上面有一个文件,编码为gbk,将其上传到Linux虚拟机,系统编码为utf-8, 使用cat命令查看时是乱码,这时如何解决? [root@localhost ~]# ...
- uva-188-枚举
题意:直接模拟 注意,w[i]不能是0 #include <string> #include<iostream> #include<map> #include< ...
- py库: django (web框架)
http://www.imooc.com/learn/736 Python-走进Requests库 http://www.imooc.com/learn/790 django入门与实践 http:// ...
- C#利用反射动态调用DLL并返回结果,和获取程序集的信息
反射的基本概念: .Net Framework 中提供了反射机制,可以再加载程序运行时,动态获取和加载程序集,并且可以获取到程序集的信息 创建Assembly和Entity两个程序集,在Assembl ...
- 原生JavaScript实现新手引导效果(第二个玩具)
慕课地址https://www.imooc.com/video/169 预览效果: <!DOCTYPE html> <html> <head> <meta c ...
- Flex Iris效果放大或缩小组件演示
Iris效果通过扩展或收缩集中在目标上的矩形遮罩为效果目标设置动画.该效果可以从目标的中心放大遮罩来显示目标,也可以向中心收缩遮罩来隐藏目标.演示: 源码如下: <?xml version=&q ...
- shell doc
参考: http://c.biancheng.net/view/1114.html
- spring data jpa update
一:在controller 加上: @Controller @RequestMapping("/user") public class UserController { @Aut ...
- javascript中的立即执行函数(function(){…})()
javascript中的立即执行函数(function(){…})() 深入理解javascript中的立即执行函数,立即执行函数也叫立即调用函数,通常它的写法是用(function(){…})()包 ...
- golang执行shell命令
ommand := "echo hello” cmd := exec.Command("/bin/bash", "-c", command) byte ...