~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to mysql-test/suite/rpl/r/rpl_loaddata.result

  • Committer: brian
  • Date: 2008-06-25 05:29:13 UTC
  • Revision ID: brian@localhost.localdomain-20080625052913-6upwo0jsrl4lnapl
clean slate

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
stop slave;
 
2
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
 
3
reset master;
 
4
reset slave;
 
5
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
 
6
start slave;
 
7
reset master;
 
8
select last_insert_id();
 
9
last_insert_id()
 
10
0
 
11
create table t1(a int not null auto_increment, b int, primary key(a) );
 
12
load data infile '../std_data_ln/rpl_loaddata.dat' into table t1;
 
13
select last_insert_id();
 
14
last_insert_id()
 
15
1
 
16
create temporary table t2 (day date,id int(9),category enum('a','b','c'),name varchar(60));
 
17
load data infile '../std_data_ln/rpl_loaddata2.dat' into table t2 fields terminated by ',' optionally enclosed by '%' escaped by '@' lines terminated by '\n##\n' starting by '>' ignore 1 lines;
 
18
create table t3 (day date,id int(9),category enum('a','b','c'),name varchar(60));
 
19
insert into t3 select * from t2;
 
20
select * from t1;
 
21
a       b
 
22
1       10
 
23
2       15
 
24
select * from t3;
 
25
day     id      category        name
 
26
2003-02-22      2461    b       a a a @ %  ' " a
 
27
2003-03-22      2161    c       asdf
 
28
2003-03-22      2416    a       bbbbb
 
29
drop table t1;
 
30
drop table t2;
 
31
drop table t3;
 
32
create table t1(a int, b int, unique(b));
 
33
insert into t1 values(1,10);
 
34
load data infile '../std_data_ln/rpl_loaddata.dat' into table t1;
 
35
set global sql_slave_skip_counter=1;
 
36
start slave;
 
37
show slave status;;
 
38
Slave_IO_State  #
 
39
Master_Host     127.0.0.1
 
40
Master_User     root
 
41
Master_Port     MASTER_PORT
 
42
Connect_Retry   1
 
43
Master_Log_File master-bin.000001
 
44
Read_Master_Log_Pos     1798
 
45
Relay_Log_File  #
 
46
Relay_Log_Pos   #
 
47
Relay_Master_Log_File   master-bin.000001
 
48
Slave_IO_Running        Yes
 
49
Slave_SQL_Running       Yes
 
50
Replicate_Do_DB 
 
51
Replicate_Ignore_DB     
 
52
Replicate_Do_Table      
 
53
Replicate_Ignore_Table  #
 
54
Replicate_Wild_Do_Table 
 
55
Replicate_Wild_Ignore_Table     
 
56
Last_Errno      0
 
57
Last_Error      
 
58
Skip_Counter    0
 
59
Exec_Master_Log_Pos     1798
 
60
Relay_Log_Space #
 
61
Until_Condition None
 
62
Until_Log_File  
 
63
Until_Log_Pos   0
 
64
Master_SSL_Allowed      No
 
65
Master_SSL_CA_File      
 
66
Master_SSL_CA_Path      
 
67
Master_SSL_Cert 
 
68
Master_SSL_Cipher       
 
69
Master_SSL_Key  
 
70
Seconds_Behind_Master   #
 
71
Master_SSL_Verify_Server_Cert   No
 
72
Last_IO_Errno   0
 
73
Last_IO_Error   
 
74
Last_SQL_Errno  0
 
75
Last_SQL_Error  
 
76
set sql_log_bin=0;
 
77
delete from t1;
 
78
set sql_log_bin=1;
 
79
load data infile '../std_data_ln/rpl_loaddata.dat' into table t1;
 
80
stop slave;
 
81
change master to master_user='test';
 
82
change master to master_user='root';
 
83
show slave status;;
 
84
Slave_IO_State  #
 
85
Master_Host     127.0.0.1
 
86
Master_User     root
 
87
Master_Port     MASTER_PORT
 
88
Connect_Retry   1
 
89
Master_Log_File master-bin.000001
 
90
Read_Master_Log_Pos     1833
 
91
Relay_Log_File  #
 
92
Relay_Log_Pos   #
 
93
Relay_Master_Log_File   master-bin.000001
 
94
Slave_IO_Running        No
 
95
Slave_SQL_Running       No
 
96
Replicate_Do_DB 
 
97
Replicate_Ignore_DB     
 
98
Replicate_Do_Table      
 
99
Replicate_Ignore_Table  #
 
100
Replicate_Wild_Do_Table 
 
101
Replicate_Wild_Ignore_Table     
 
102
Last_Errno      0
 
103
Last_Error      
 
104
Skip_Counter    0
 
105
Exec_Master_Log_Pos     1833
 
106
Relay_Log_Space #
 
107
Until_Condition None
 
108
Until_Log_File  
 
109
Until_Log_Pos   0
 
110
Master_SSL_Allowed      No
 
111
Master_SSL_CA_File      
 
112
Master_SSL_CA_Path      
 
113
Master_SSL_Cert 
 
114
Master_SSL_Cipher       
 
115
Master_SSL_Key  
 
116
Seconds_Behind_Master   #
 
117
Master_SSL_Verify_Server_Cert   No
 
118
Last_IO_Errno   0
 
119
Last_IO_Error   
 
120
Last_SQL_Errno  0
 
121
Last_SQL_Error  
 
122
set global sql_slave_skip_counter=1;
 
123
start slave;
 
124
set sql_log_bin=0;
 
125
delete from t1;
 
126
set sql_log_bin=1;
 
127
load data infile '../std_data_ln/rpl_loaddata.dat' into table t1;
 
128
stop slave;
 
129
reset slave;
 
130
show slave status;;
 
131
Slave_IO_State  #
 
132
Master_Host     127.0.0.1
 
133
Master_User     root
 
134
Master_Port     MASTER_PORT
 
135
Connect_Retry   1
 
136
Master_Log_File 
 
137
Read_Master_Log_Pos     4
 
138
Relay_Log_File  #
 
139
Relay_Log_Pos   #
 
140
Relay_Master_Log_File   
 
141
Slave_IO_Running        No
 
142
Slave_SQL_Running       No
 
143
Replicate_Do_DB 
 
144
Replicate_Ignore_DB     
 
145
Replicate_Do_Table      
 
146
Replicate_Ignore_Table  #
 
147
Replicate_Wild_Do_Table 
 
148
Replicate_Wild_Ignore_Table     
 
149
Last_Errno      0
 
150
Last_Error      
 
151
Skip_Counter    0
 
152
Exec_Master_Log_Pos     0
 
153
Relay_Log_Space #
 
154
Until_Condition None
 
155
Until_Log_File  
 
156
Until_Log_Pos   0
 
157
Master_SSL_Allowed      No
 
158
Master_SSL_CA_File      
 
159
Master_SSL_CA_Path      
 
160
Master_SSL_Cert 
 
161
Master_SSL_Cipher       
 
162
Master_SSL_Key  
 
163
Seconds_Behind_Master   #
 
164
Master_SSL_Verify_Server_Cert   No
 
165
Last_IO_Errno   0
 
166
Last_IO_Error   
 
167
Last_SQL_Errno  0
 
168
Last_SQL_Error  
 
169
reset master;
 
170
create table t2 (day date,id int(9),category enum('a','b','c'),name varchar(60),
 
171
unique(day)) engine=MyISAM;
 
172
load data infile '../std_data_ln/rpl_loaddata2.dat' into table t2 fields
 
173
terminated by ',' optionally enclosed by '%' escaped by '@' lines terminated by
 
174
'\n##\n' starting by '>' ignore 1 lines;
 
175
ERROR 23000: Duplicate entry '2003-03-22' for key 'day'
 
176
select * from t2;
 
177
day     id      category        name
 
178
2003-02-22      2461    b       a a a @ %  ' " a
 
179
2003-03-22      2161    c       asdf
 
180
start slave;
 
181
select * from t2;
 
182
day     id      category        name
 
183
2003-02-22      2461    b       a a a @ %  ' " a
 
184
2003-03-22      2161    c       asdf
 
185
alter table t2 drop key day;
 
186
delete from t2;
 
187
load data infile '../std_data_ln/rpl_loaddata2.dat' into table t2 fields
 
188
terminated by ',' optionally enclosed by '%' escaped by '@' lines terminated by
 
189
'\n##\n' starting by '>' ignore 1 lines;
 
190
ERROR 23000: Duplicate entry '2003-03-22' for key 'day'
 
191
drop table t2;
 
192
drop table t2;
 
193
drop table t1;
 
194
CREATE TABLE t1 (word CHAR(20) NOT NULL PRIMARY KEY) ENGINE=INNODB;
 
195
LOAD DATA INFILE "../std_data_ln/words.dat" INTO TABLE t1;
 
196
ERROR 23000: Duplicate entry 'Aarhus' for key 'PRIMARY'
 
197
DROP TABLE IF EXISTS t1;