⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 type_newdecimal.result

📁 这是linux下运行的mysql软件包,可用于linux 下安装 php + mysql + apach 的网络配置
💻 RESULT
📖 第 1 页 / 共 3 页
字号:
-16select round(15.1,1);round(15.1,1)15.1select round(15.4,1);round(15.4,1)15.4select round(15.5,1);round(15.5,1)15.5select round(15.6,1);round(15.6,1)15.6select round(15.9,1);round(15.9,1)15.9select round(-15.1,1);round(-15.1,1)-15.1select round(-15.4,1);round(-15.4,1)-15.4select round(-15.5,1);round(-15.5,1)-15.5select round(-15.6,1);round(-15.6,1)-15.6select round(-15.9,1);round(-15.9,1)-15.9select round(15.1,0);round(15.1,0)15select round(15.4,0);round(15.4,0)15select round(15.5,0);round(15.5,0)16select round(15.6,0);round(15.6,0)16select round(15.9,0);round(15.9,0)16select round(-15.1,0);round(-15.1,0)-15select round(-15.4,0);round(-15.4,0)-15select round(-15.5,0);round(-15.5,0)-16select round(-15.6,0);round(-15.6,0)-16select round(-15.9,0);round(-15.9,0)-16select round(15.1,-1);round(15.1,-1)20select round(15.4,-1);round(15.4,-1)20select round(15.5,-1);round(15.5,-1)20select round(15.6,-1);round(15.6,-1)20select round(15.9,-1);round(15.9,-1)20select round(-15.1,-1);round(-15.1,-1)-20select round(-15.4,-1);round(-15.4,-1)-20select round(-15.5,-1);round(-15.5,-1)-20select round(-15.6,-1);round(-15.6,-1)-20select round(-15.91,-1);round(-15.91,-1)-20select truncate(5678.123451,0);truncate(5678.123451,0)5678select truncate(5678.123451,1);truncate(5678.123451,1)5678.1select truncate(5678.123451,2);truncate(5678.123451,2)5678.12select truncate(5678.123451,3);truncate(5678.123451,3)5678.123select truncate(5678.123451,4);truncate(5678.123451,4)5678.1234select truncate(5678.123451,5);truncate(5678.123451,5)5678.12345select truncate(5678.123451,6);truncate(5678.123451,6)5678.123451select truncate(5678.123451,-1);truncate(5678.123451,-1)5670select truncate(5678.123451,-2);truncate(5678.123451,-2)5600select truncate(5678.123451,-3);truncate(5678.123451,-3)5000select truncate(5678.123451,-4);truncate(5678.123451,-4)0select truncate(-5678.123451,0);truncate(-5678.123451,0)-5678select truncate(-5678.123451,1);truncate(-5678.123451,1)-5678.1select truncate(-5678.123451,2);truncate(-5678.123451,2)-5678.12select truncate(-5678.123451,3);truncate(-5678.123451,3)-5678.123select truncate(-5678.123451,4);truncate(-5678.123451,4)-5678.1234select truncate(-5678.123451,5);truncate(-5678.123451,5)-5678.12345select truncate(-5678.123451,6);truncate(-5678.123451,6)-5678.123451select truncate(-5678.123451,-1);truncate(-5678.123451,-1)-5670select truncate(-5678.123451,-2);truncate(-5678.123451,-2)-5600select truncate(-5678.123451,-3);truncate(-5678.123451,-3)-5000select truncate(-5678.123451,-4);truncate(-5678.123451,-4)0create table wl1612_4 (col1 int, col2 decimal(30,25), col3 numeric(30,25));insert into wl1612_4 values(1,0.0123456789012345678912345,0.0123456789012345678912345);select col2/9999999999 from wl1612_4 where col1=1;col2/99999999990.00000000000123456789024691358select col3/9999999999 from wl1612_4 where col1=1;col3/99999999990.00000000000123456789024691358select 9999999999/col2 from wl1612_4 where col1=1;9999999999/col2810000007209.0001select 9999999999/col3 from wl1612_4 where col1=1;9999999999/col3810000007209.0001select col2*9999999999 from wl1612_4 where col1=1;col2*9999999999123456789.0000000000111104321087655select col3*9999999999 from wl1612_4 where col1=1;col3*9999999999123456789.0000000000111104321087655insert into wl1612_4 values(2,55555.0123456789012345678912345,55555.0123456789012345678912345);select col2/9999999999 from wl1612_4 where col1=2;col2/99999999990.00000555550123512344024696913select col3/9999999999 from wl1612_4 where col1=2;col3/99999999990.00000555550123512344024696913select 9999999999/col2 from wl1612_4 where col1=2;9999999999/col2180001.7600select 9999999999/col3 from wl1612_4 where col1=2;9999999999/col3180001.7600select col2*9999999999 from wl1612_4 where col1=2;col2*9999999999555550123401234.0000000000111104321087655select col3*9999999999 from wl1612_4 where col1=2;col3*9999999999555550123401234.0000000000111104321087655drop table wl1612_4;set sql_mode='';select 23.4 + (-41.7), 23.4 - (41.7) = -18.3;23.4 + (-41.7)	23.4 - (41.7) = -18.3-18.3	1select -18.3=-18.3;-18.3=-18.31select 18.3=18.3;18.3=18.31select -18.3=18.3;-18.3=18.30select 0.8 = 0.7 + 0.1;0.8 = 0.7 + 0.11drop table if exists t1;Warnings:Note	1051	Unknown table 't1'create table t1 (col1 decimal(38));insert into t1 values (12345678901234567890123456789012345678);select * from t1;col112345678901234567890123456789012345678drop table t1;create table t1 (col1 decimal(31,30));insert into t1 values (0.00000000001);select * from t1;col10.000000000010000000000000000000drop table t1;select 7777777777777777777777777777777777777 * 10;7777777777777777777777777777777777777 * 1077777777777777777777777777777777777770select .7777777777777777777777777777777777777 *1000000000000000000;.7777777777777777777777777777777777777 *1000000000000000000777777777777777777.777777777777777777700000000000select .7777777777777777777777777777777777777 - 0.1;.7777777777777777777777777777777777777 - 0.10.6777777777777777777777777777777777777select .343434343434343434 + .343434343434343434;.343434343434343434 + .3434343434343434340.686868686868686868select abs(9999999999999999999999);abs(9999999999999999999999)9999999999999999999999select abs(-9999999999999999999999);abs(-9999999999999999999999)9999999999999999999999select ceiling(999999999999999999);ceiling(999999999999999999)999999999999999999select ceiling(99999999999999999999);ceiling(99999999999999999999)99999999999999999999select ceiling(9.9999999999999999999);ceiling(9.9999999999999999999)10select ceiling(-9.9999999999999999999);ceiling(-9.9999999999999999999)-9select floor(999999999999999999);floor(999999999999999999)999999999999999999select floor(9999999999999999999999);floor(9999999999999999999999)9999999999999999999999select floor(9.999999999999999999999);floor(9.999999999999999999999)9select floor(-9.999999999999999999999);floor(-9.999999999999999999999)-10select floor(-999999999999999999999.999);floor(-999999999999999999999.999)-1000000000000000000000select ceiling(999999999999999999999.999);ceiling(999999999999999999999.999)1000000000000000000000select 99999999999999999999999999999999999999 mod 3;99999999999999999999999999999999999999 mod 30select round(99999999999999999.999);round(99999999999999999.999)100000000000000000select round(-99999999999999999.999);round(-99999999999999999.999)-100000000000000000select round(99999999999999999.999,3);round(99999999999999999.999,3)99999999999999999.999select round(-99999999999999999.999,3);round(-99999999999999999.999,3)-99999999999999999.999select truncate(99999999999999999999999999999999999999,31);truncate(99999999999999999999999999999999999999,31)99999999999999999999999999999999999999.000000000000000000000000000000select truncate(99.999999999999999999999999999999999999,31);truncate(99.999999999999999999999999999999999999,31)100.000000000000000000000000000000select truncate(99999999999999999999999999999999999999,-31);truncate(99999999999999999999999999999999999999,-31)99999990000000000000000000000000000000create table t1 as select 0.5;show create table t1;Table	Create Tablet1	CREATE TABLE `t1` (  `0.5` decimal(2,1) unsigned NOT NULL default '0.0') ENGINE=MyISAM DEFAULT CHARSET=latin1drop table t1;select round(1.5),round(2.5);round(1.5)	round(2.5)2	3select 0.07 * 0.07;0.07 * 0.070.0049set sql_mode='traditional';select 1E-500 = 0;1E-500 = 01select 1 / 1E-500;1 / 1E-500NULLWarnings:Error	1365	Division by 0select 1 / 0;1 / 0NULLWarnings:Error	1365	Division by 0set sql_mode='ansi,traditional';CREATE TABLE Sow6_2f (col1 NUMERIC(4,2));INSERT INTO Sow6_2f VALUES (10.55);INSERT INTO Sow6_2f VALUES (10.5555);Warnings:Note	1265	Data truncated for column 'col1' at row 1INSERT INTO Sow6_2f VALUES (-10.55);INSERT INTO Sow6_2f VALUES (-10.5555);Warnings:Note	1265	Data truncated for column 'col1' at row 1INSERT INTO Sow6_2f VALUES (11);INSERT INTO Sow6_2f VALUES (101.55);ERROR 22003: Out of range value adjusted for column 'col1' at row 1UPDATE Sow6_2f SET col1 = col1 * 50 WHERE col1 = 11;ERROR 22003: Out of range value adjusted for column 'col1' at row 5UPDATE Sow6_2f SET col1 = col1 / 0 WHERE col1 > 0;ERROR 22012: Division by 0SELECT MOD(col1,0) FROM Sow6_2f;MOD(col1,0)NULLNULLNULLNULLNULLWarnings:Error	1365	Division by 0Error	1365	Division by 0Error	1365	Division by 0Error	1365	Division by 0Error	1365	Division by 0INSERT INTO Sow6_2f VALUES ('a59b');ERROR HY000: Incorrect decimal value: 'a59b' for column 'col1' at row 1drop table Sow6_2f;select 10.3330000000000/12.34500000;10.3330000000000/12.345000000.83701903604698258set sql_mode='';select 0/0;0/0NULLselect 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 as x;x99999999999999999999999999999999999999999999999999999999999999999Warnings:Error	1292	Truncated incorrect DECIMAL value: ''select 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999 + 1 as x;x100000000000000000000000000000000000000000000000000000000000000000Warnings:Error	1292	Truncated incorrect DECIMAL value: ''select 0.190287977636363637 + 0.040372670 * 0 -  0;0.190287977636363637 + 0.040372670 * 0 -  00.190287977636363637select -0.123 * 0;-0.123 * 00.000CREATE TABLE t1 (f1 DECIMAL (12,9), f2 DECIMAL(2,2));INSERT INTO t1 VALUES (10.5, 0);UPDATE t1 SET f1 = 4.5;SELECT * FROM t1;f1	f24.500000000	0.00DROP TABLE t1;CREATE TABLE t1 (f1 DECIMAL (64,20), f2 DECIMAL(2,2));INSERT INTO t1 VALUES (9999999999999999999999999999999999, 0);SELECT * FROM t1;f1	f29999999999999999999999999999999999.00000000000000000000	0.00DROP TABLE t1;select abs(10/0);abs(10/0)NULLselect abs(NULL);abs(NULL)NULLset @@sql_mode='traditional';create table t1( d1 decimal(18) unsigned, d2 decimal(20) unsigned, d3 decimal (22) unsigned);insert into t1 values(1,-1,-1);ERROR 22003: Out of range value adjusted for column 'd2' at row 1drop table t1;create table t1 (col1 decimal(5,2), col2 numeric(5,2));insert into t1 values (999.999,999.999);ERROR 22003: Out of range value adjusted for column 'col1' at row 1insert into t1 values (-999.999,-999.999);ERROR 22003: Out of range value adjusted for column 'col1' at row 1select * from t1;col1	col2drop table t1;set sql_mode='';set @sav_dpi= @@div_precision_increment;set @@div_precision_increment=15;create table t1 (col1 int, col2 decimal(30,25), col3 numeric(30,25));insert into t1 values (1,0.0123456789012345678912345,0.0123456789012345678912345);select col2/9999999999 from t1 where col1=1;col2/99999999990.000000000001234567890246913578select 9999999999/col2 from t1 where col1=1;9999999999/col2810000007209.000065537105051select 77777777/7777777;77777777/777777710.000000900000090drop table t1;set div_precision_increment= @sav_dpi;create table t1 (a decimal(4,2));insert into t1 values (0.00);select * from t1 where a > -0.00;aselect * from t1 where a = -0.00;a0.00drop table t1;create table t1 (col1 bigint default -9223372036854775808);insert into t1 values (default);select * from t1;col1-9223372036854775808drop table t1;select cast('1.00000001335143196001808973960578441619873046875E-10' as decimal(30,15));cast('1.00000001335143196001808973960578441619873046875E-10' as decimal(30,15))0.000000000100000select ln(14000) c1, convert(ln(14000),decimal(2,3)) c2, cast(ln(14000) as decimal(2,3)) c3;c1	c2	c39.5468126085974	9.547	9.547create table t1 (sl decimal(70,30));ERROR 42000: Too big precision 70 specified for column 'sl'. Maximum is 65.create table t1 (sl decimal(32,31));ERROR 42000: Too big scale 31 specified for column 'sl'. Maximum is 30.create table t1 (sl decimal(0,38));ERROR 42000: Too big scale 38 specified for column 'sl'. Maximum is 30.create table t1 (sl decimal(0,30));ERROR 42000: For float(M,D), double(M,D) or decimal(M,D), M must be >= D (column 'sl').create table t1 (sl decimal(5, 5));show create table t1;Table	Create Tablet1	CREATE TABLE `t1` (  `sl` decimal(5,5) default NULL) ENGINE=MyISAM DEFAULT CHARSET=latin1

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -