Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
854076da
Commit
854076da
authored
Feb 06, 2004
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
3.23 -> 4.0 merge: after merge fixes
parent
5db2d195
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
41 additions
and
0 deletions
+41
-0
mysql-test/r/alter_table.result
mysql-test/r/alter_table.result
+13
-0
mysql-test/r/func_math.result
mysql-test/r/func_math.result
+6
-0
mysql-test/r/insert_select.result
mysql-test/r/insert_select.result
+19
-0
mysql-test/t/insert_select.test
mysql-test/t/insert_select.test
+2
-0
sql/sql_table.cc
sql/sql_table.cc
+1
-0
No files found.
mysql-test/r/alter_table.result
View file @
854076da
...
...
@@ -350,11 +350,24 @@ t1 0 PRIMARY 1 Host A NULL NULL NULL BTREE
t1 0 PRIMARY 2 User A 0 NULL NULL BTREE
t1 1 Host 1 Host A NULL NULL NULL BTREE disabled
DROP TABLE t1;
create table t1 (name char(15));
insert into t1 (name) values ("current");
create database mysqltest;
create table mysqltest.t1 (name char(15));
insert into mysqltest.t1 (name) values ("mysqltest");
select * from t1;
name
current
select * from mysqltest.t1;
name
mysqltest
alter table t1 rename mysqltest.t1;
Table 't1' already exists
select * from t1;
name
current
select * from mysqltest.t1;
name
mysqltest
drop table t1;
drop database mysqltest;
mysql-test/r/func_math.result
View file @
854076da
...
...
@@ -41,15 +41,21 @@ pi() sin(pi()/2) cos(pi()/2) abs(tan(pi())) cot(1) asin(1) acos(0) atan(1)
select degrees(pi()),radians(360);
degrees(pi()) radians(360)
180 6.2831853071796
SELECT ACOS(1.0);
ACOS(1.0)
0.000000
SELECT ASIN(1.0);
ASIN(1.0)
1.570796
SELECT ACOS(0.2*5.0);
ACOS(0.2*5.0)
0.000000
SELECT ACOS(0.5*2.0);
ACOS(0.5*2.0)
0.000000
SELECT ASIN(0.8+0.2);
ASIN(0.8+0.2)
1.570796
SELECT ASIN(1.2-0.2);
ASIN(1.2-0.2)
1.570796
mysql-test/r/insert_select.result
View file @
854076da
...
...
@@ -592,15 +592,34 @@ CREATE TABLE t2 ( USID INTEGER UNSIGNED AUTO_INCREMENT, ServerID TINYINT UNSIGNE
INSERT INTO t1 VALUES (39,42,'Access-Granted','46','491721000045',2130706433,17690,NULL,NULL,'Localnet','491721000045','49172200000',754974766,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'2003-07-18 00:11:21',NULL,NULL,20030718001121);
INSERT INTO t2 SELECT USID, ServerID, State, SessionID, User, NASAddr, NASPort, NASPortType, ConnectSpeed, CarrierType, CallingStationID, CalledStationID, AssignedAddr, SessionTime, PacketsIn, OctetsIn, PacketsOut, OctetsOut, TerminateCause, UnauthTime, AccessRequestTime, AcctStartTime, AcctLastTime, LastModification from t1 LIMIT 1;
drop table t1,t2;
CREATE TABLE t1(
Month date NOT NULL,
Type tinyint(3) unsigned NOT NULL auto_increment,
Field int(10) unsigned NOT NULL,
Count int(10) unsigned NOT NULL,
UNIQUE KEY Month (Month,Type,Field)
);
insert into t1 Values
(20030901, 1, 1, 100),
(20030901, 1, 2, 100),
(20030901, 2, 1, 100),
(20030901, 2, 2, 100),
(20030901, 3, 1, 100);
select * from t1;
Month Type Field Count
2003-09-01 1 1 100
2003-09-01 1 2 100
2003-09-01 2 1 100
2003-09-01 2 2 100
2003-09-01 3 1 100
Select null, Field, Count From t1 Where Month=20030901 and Type=2;
NULL Field Count
NULL 1 100
NULL 2 100
create table t2(No int not null, Field int not null, Count int not null);
insert into t2 Select null, Field, Count From t1 Where Month=20030901 and Type=2;
select * from t2;
No Field Count
0 1 100
0 2 100
drop table t1, t2;
mysql-test/t/insert_select.test
View file @
854076da
...
...
@@ -132,6 +132,8 @@ CREATE TABLE t2 ( USID INTEGER UNSIGNED AUTO_INCREMENT, ServerID TINYINT UNSIGNE
INSERT
INTO
t1
VALUES
(
39
,
42
,
'Access-Granted'
,
'46'
,
'491721000045'
,
2130706433
,
17690
,
NULL
,
NULL
,
'Localnet'
,
'491721000045'
,
'49172200000'
,
754974766
,
NULL
,
NULL
,
NULL
,
NULL
,
NULL
,
NULL
,
NULL
,
'2003-07-18 00:11:21'
,
NULL
,
NULL
,
20030718001121
);
INSERT
INTO
t2
SELECT
USID
,
ServerID
,
State
,
SessionID
,
User
,
NASAddr
,
NASPort
,
NASPortType
,
ConnectSpeed
,
CarrierType
,
CallingStationID
,
CalledStationID
,
AssignedAddr
,
SessionTime
,
PacketsIn
,
OctetsIn
,
PacketsOut
,
OctetsOut
,
TerminateCause
,
UnauthTime
,
AccessRequestTime
,
AcctStartTime
,
AcctLastTime
,
LastModification
from
t1
LIMIT
1
;
drop
table
t1
,
t2
;
#
# Another problem from Bug #2012
#
...
...
sql/sql_table.cc
View file @
854076da
...
...
@@ -1490,6 +1490,7 @@ int mysql_alter_table(THD *thd,char *new_db, char *new_name,
if
(
new_name
)
{
strmov
(
new_name_buff
,
new_name
);
strmov
(
new_alias
=
new_alias_buff
,
new_name
);
if
(
lower_case_table_names
)
{
if
(
lower_case_table_names
!=
2
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment