~stewart/drizzle/embedded-innodb-create-select-transaction-arrgh

« back to all changes in this revision

Viewing changes to mysql-test/suite/rpl/t/rpl_loadfile.test

  • 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
#############################################################################
 
2
# Original Author: JBM                                                      #
 
3
# Original Date: Aug/18/2005                                                #
 
4
#############################################################################
 
5
# TEST: To test the LOAD_FILE() in rbr                                      #
 
6
#############################################################################
 
7
# Change Author: JBM
 
8
# Change Date: 2006-01-16
 
9
# Change: Added Order by for NDB
 
10
##########
 
11
 
 
12
# Includes
 
13
-- source include/master-slave.inc
 
14
 
 
15
 
 
16
# Begin clean up test section
 
17
--disable_warnings
 
18
connection master;
 
19
DROP PROCEDURE IF EXISTS test.p1;
 
20
DROP TABLE IF EXISTS test.t1;
 
21
--enable_warnings
 
22
 
 
23
# Section 1 test 
 
24
 
 
25
CREATE TABLE test.t1 (a INT, blob_column LONGBLOB, PRIMARY KEY(a));
 
26
INSERT INTO test.t1  VALUES(1,'test');
 
27
UPDATE test.t1 SET blob_column=LOAD_FILE('../std_data_ln/words2.dat') WHERE a=1;
 
28
delimiter |;
 
29
create procedure test.p1()
 
30
begin
 
31
  INSERT INTO test.t1  VALUES(2,'test');
 
32
  UPDATE test.t1 SET blob_column=LOAD_FILE('../std_data_ln/words2.dat') WHERE a=2;
 
33
end|
 
34
delimiter ;|
 
35
 
 
36
CALL test.p1();
 
37
SELECT * FROM test.t1 ORDER BY blob_column;
 
38
save_master_pos;
 
39
sync_slave_with_master;
 
40
connection slave;
 
41
# Need to allow some time when NDB engine is used for
 
42
# the injector thread to have time to populate binlog
 
43
let $wait_condition= SELECT INSTR(blob_column,'aberration') > 0 FROM test.t1 WHERE a = 2;
 
44
--source include/wait_condition.inc
 
45
SELECT * FROM test.t1 ORDER BY blob_column;
 
46
 
 
47
# Cleanup
 
48
connection master;
 
49
DROP PROCEDURE IF EXISTS test.p1;
 
50
DROP TABLE test.t1;
 
51
sync_slave_with_master;
 
52
 
 
53
# End of 5.0 test case