SQLite

Check-in [5b9b66f47b]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Add a test case for ticket #3879. (CVS 6675)
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 5b9b66f47b0b8178427806149958387d32b70dc2
User & Date: danielk1977 2009-05-25 11:46:11.000
Context
2009-05-25
11:46
When pinning a temp register after it is reused by the column cache, make sure all instances of that register in the cache are pinned so that the register is never reused for a different purpose. Ticket #3879. (CVS 6676) (check-in: 5f358e6371 user: drh tags: trunk)
11:46
Add a test case for ticket #3879. (CVS 6675) (check-in: 5b9b66f47b user: danielk1977 tags: trunk)
2009-05-24
21:59
Additional clarification of the 3rd parameter to sqlite3_create_function(). Documentation change only; no changes to code. Ticket #3875. (CVS 6674) (check-in: dd75e376e8 user: drh tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Added test/tkt3879.test.










































































































>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# 2009 May 25
#
# The author disclaims copyright to this source code.  In place of
# a legal notice, here is a blessing:
#
#    May you do good and not evil.
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#***********************************************************************
#
# Tests to verify ticket #3879 is fixed.
#
# $Id: tkt3879.test,v 1.1 2009/05/25 11:46:11 danielk1977 Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl

do_test tkt3879.1.1 {
  execsql {
    CREATE TABLE t1 (a PRIMARY KEY, b);
    INSERT INTO t1 VALUES ('w',  1);
    INSERT INTO t1 VALUES ('z', -1);
  
    CREATE TABLE t2 (m INTEGER PRIMARY KEY, n, a, p);
    INSERT INTO t2 VALUES (25, 13, 'w', 1);
    INSERT INTO t2 VALUES (26, 25, 'z', 153);
    INSERT INTO t2 VALUES (27, 25, 'z', 68);

    CREATE TABLE t3 (m);
    INSERT INTO t3 VALUES (25);
  }
} {}

do_test tkt3879.1.2 {
  execsql {
    SELECT 111, t1.b*123
    FROM t3, t2 AS j0, t2 AS j1, t1
    WHERE j0.m=t3.m AND t1.a=j0.a AND j1.n=j0.m;
  }
} {111 123 111 123}

do_test tkt3879.1.3 {
  execsql {
    SELECT 222, t1.b*123
    FROM t3, t2 AS j0, t2 AS j1, t1
    WHERE j0.m=t3.m AND t1.a=j0.a AND j1.n=j0.m
    ORDER BY t1.b;
  }
} {222 123 222 123}

finish_test