Fossil

Check-in [fb8dc7d0]
Login

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

Overview
Comment:The UNIQUE constraint on the default TICKET table was wrong. The tkt_uuid column should be unique unto itself, not in combination with tkt_time. Existing servers will need to fix their TICKET implementations using the setup menu. This check-in changes the default.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:fb8dc7d07f8e9ac0dda84ee16a1d7b0a5b973f1a
User & Date: drh 2008-10-05 13:13:13
Context
2008-10-06
00:31
Documentation update: Add the "Questions and Criticisms" document in response to recent comments on reddit.com. check-in: cbc89836 user: drh tags: trunk
2008-10-05
13:13
The UNIQUE constraint on the default TICKET table was wrong. The tkt_uuid column should be unique unto itself, not in combination with tkt_time. Existing servers will need to fix their TICKET implementations using the setup menu. This check-in changes the default. check-in: fb8dc7d0 user: drh tags: trunk
12:34
Get cloning working for local files without the use of network I/O. Ticket [b3482d580e]. check-in: 9236f0c0 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/schema.c.

276
277
278
279
280
281
282



283

284
285
286
287











288
289
290
291
292
293
294
@   rid INTEGER REFERENCE blob,     -- Baseline that tag added/removed from
@   UNIQUE(rid, tagid)
@ );
@ CREATE INDEX tagxref_i1 ON tagxref(tagid, mtime);
@
@ -- Template for the TICKET table
@ --



@ CREATE TABLE ticket(

@   tkt_id INTEGER PRIMARY KEY,
@   tkt_uuid TEXT,
@   tkt_mtime REAL,
@   UNIQUE(tkt_uuid, tkt_mtime)











@ );
;

/*
** Predefined tagid values
*/
#if INTERFACE







>
>
>

>

|
|
<
>
>
>
>
>
>
>
>
>
>
>







276
277
278
279
280
281
282
283
284
285
286
287
288
289
290

291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
@   rid INTEGER REFERENCE blob,     -- Baseline that tag added/removed from
@   UNIQUE(rid, tagid)
@ );
@ CREATE INDEX tagxref_i1 ON tagxref(tagid, mtime);
@
@ -- Template for the TICKET table
@ --
@ -- NB: when changing the schema of the TICKET table here, also make the
@ -- same change in tktsetup.c.
@ --
@ CREATE TABLE ticket(
@   -- Do not change any column that begins with tkt_
@   tkt_id INTEGER PRIMARY KEY,
@   tkt_uuid TEXT UNIQUE,
@   tkt_mtime DATE,

@   -- Add as many field as required below this line
@   type TEXT,
@   status TEXT,
@   subsystem TEXT,
@   priority TEXT,
@   severity TEXT,
@   foundin TEXT,
@   private_contact TEXT,
@   resolution TEXT,
@   title TEXT,
@   comment TEXT
@ );
;

/*
** Predefined tagid values
*/
#if INTERFACE

Changes to src/tktsetup.c.

63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
** equivalent definition found in schema.c.
*/
/* @-comment: ** */
static const char zDefaultTicketTable[] =
@ CREATE TABLE ticket(
@   -- Do not change any column that begins with tkt_
@   tkt_id INTEGER PRIMARY KEY,
@   tkt_uuid TEXT,
@   tkt_mtime DATE,
@   -- Add as many field as required below this line
@   type TEXT,
@   status TEXT,
@   subsystem TEXT,
@   priority TEXT,
@   severity TEXT,
@   foundin TEXT,
@   private_contact TEXT,
@   resolution TEXT,
@   title TEXT,
@   comment TEXT,
@   -- Do not alter this UNIQUE clause:
@   UNIQUE(tkt_uuid, tkt_mtime)
@ );
;

/*
** Return the ticket table definition
*/
const char *ticket_table_schema(void){







|











|
<
<







63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82


83
84
85
86
87
88
89
** equivalent definition found in schema.c.
*/
/* @-comment: ** */
static const char zDefaultTicketTable[] =
@ CREATE TABLE ticket(
@   -- Do not change any column that begins with tkt_
@   tkt_id INTEGER PRIMARY KEY,
@   tkt_uuid TEXT UNIQUE,
@   tkt_mtime DATE,
@   -- Add as many field as required below this line
@   type TEXT,
@   status TEXT,
@   subsystem TEXT,
@   priority TEXT,
@   severity TEXT,
@   foundin TEXT,
@   private_contact TEXT,
@   resolution TEXT,
@   title TEXT,
@   comment TEXT


@ );
;

/*
** Return the ticket table definition
*/
const char *ticket_table_schema(void){