~ubuntu-branches/ubuntu/trusty/drizzle/trusty

« back to all changes in this revision

Viewing changes to plugin/haildb/tests/r/basic_on_duplicate_key.result

  • Committer: Package Import Robot
  • Author(s): Clint Byrum
  • Date: 2012-06-19 10:46:49 UTC
  • mfrom: (1.1.6)
  • mto: This revision was merged to the branch mainline in revision 29.
  • Revision ID: package-import@ubuntu.com-20120619104649-e2l0ggd4oz3um0f4
Tags: upstream-7.1.36-stable
ImportĀ upstreamĀ versionĀ 7.1.36-stable

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
create table t1 (a int auto_increment primary key, b int, c timestamp);
2
 
insert into t1 (a, b, c) values (1, 0, '2001-01-01 01:01:01'),
3
 
(2, 0, '2002-02-02 02:02:02'), (3, 0, '2003-03-03 03:03:03');
4
 
insert into t1 (a) values (3), (5) on duplicate key update b = 3, c = c;
5
 
select * from t1;
6
 
a       b       c
7
 
1       0       2001-01-01 01:01:01
8
 
2       0       2002-02-02 02:02:02
9
 
3       3       2003-03-03 03:03:03
10
 
5       NULL    NULL
11
 
insert into t1 (a, c) values (4, '2004-04-04 00:00:00'),
12
 
(6, '2006-06-06 06:06:06') on duplicate key update b = 4;
13
 
select * from t1;
14
 
a       b       c
15
 
1       0       2001-01-01 01:01:01
16
 
2       0       2002-02-02 02:02:02
17
 
3       3       2003-03-03 03:03:03
18
 
4       NULL    2004-04-04 00:00:00
19
 
5       NULL    NULL
20
 
6       NULL    2006-06-06 06:06:06
21
 
drop table t1;