Thread: SQL99 doc update
Hi all, This fixes 2 inaccuracies in the recently added SQL99 feature list docs. UNIQUE and DISTINCT predicates are both listed as implemented -- AFAIK, neither is. I also included another trivial patch which adds the default location of the DSSSL stylesheets on my system (Debian unstable, docbook-dsssl 1.76) to the list of paths that configure looks for. Cheers, Neil -- Neil Conway <neilconway@rogers.com> PGP Key ID: DB3C29FC
Attachment
> This fixes 2 inaccuracies in the recently added SQL99 feature list docs. > UNIQUE and DISTINCT predicates are both listed as implemented -- AFAIK, > neither is. I'm working on adding the IS DISTINCT FROM clause. I haven't looked to see about UNIQUE. Remind me to readjust the docs when we get that working. > I also included another trivial patch which adds the default location > of the DSSSL stylesheets on my system (Debian unstable, docbook-dsssl > 1.76) to the list of paths that configure looks for. Great. I have had to do the same thing on my Mandrake Linux box. - Thomas
> > This fixes 2 inaccuracies in the recently added SQL99 feature list docs. > > UNIQUE and DISTINCT predicates are both listed as implemented -- AFAIK, > > neither is. > > I'm working on adding the IS DISTINCT FROM clause. I haven't looked to > see about UNIQUE. Remind me to readjust the docs when we get that > working. Where are these two new clauses used? Chris
> > > This fixes 2 inaccuracies in the recently added SQL99 feature list docs. > > > UNIQUE and DISTINCT predicates are both listed as implemented -- AFAIK, > > > neither is. > > I'm working on adding the IS DISTINCT FROM clause. I haven't looked to > > see about UNIQUE. Remind me to readjust the docs when we get that > > working. > Where are these two new clauses used? I haven't looked yet at UNIQUE. IS DISTINCT FROM takes two row expressions and compares them; if every element compares equal (or if both elements are NULL) then the two expressions are considered to be "not distinct" and FALSE is returned. Otherwise the two expressions are considered to be distinct. - Thoas
On Sun, Jun 30, 2002 at 09:10:30PM -0700, Thomas Lockhart wrote: > > This fixes 2 inaccuracies in the recently added SQL99 feature list docs. > > UNIQUE and DISTINCT predicates are both listed as implemented -- AFAIK, > > neither is. > > I'm working on adding the IS DISTINCT FROM clause. I haven't looked to > see about UNIQUE. Remind me to readjust the docs when we get that > working. Glad you mentioned that -- I've started working on UNIQUE, and I was planning to implement IS DISTINCT FROM after that (but I'm happy to let you handle that). Cheers, Neil -- Neil Conway <neilconway@rogers.com> PGP Key ID: DB3C29FC
Thomas Lockhart <lockhart@fourpalms.org> writes: >> Where are these two new clauses used? > I haven't looked yet at UNIQUE. UNIQUE is defined by SQL92 section 8.9: <unique predicate> ::= UNIQUE <table subquery> 1) Let T be the result of the <table subquery>. 2) If there are no two rows in T such that the value of each column in one row is non-null and is equal to the value of the cor- responding column in the other row according to Subclause 8.2, "<comparison predicate>", then the result of the <unique predi- cate> is true; otherwise, the result of the <unique predicate> is false. A UNIQUE constraint (implemented by a unique index in PG) is essentially an assertion holding that "UNIQUE (SELECT some-columns FROM table)" is true at all times. It'd be possible to implement the UNIQUE predicate using a simple variant of our existing Unique/Group By support. But the amount of work needed still seems out of proportion to the demand for the feature ;-). I note that SQL92 does not consider this an entry-level SQL feature --- which is odd considering that unique constraints, which are defined in terms of the unique predicate, *are* entry SQL. But in terms of usefulness I think the SQL authors got this right. regards, tom lane
Patch applied. Thanks. --------------------------------------------------------------------------- Neil Conway wrote: > Hi all, > > This fixes 2 inaccuracies in the recently added SQL99 feature list docs. > UNIQUE and DISTINCT predicates are both listed as implemented -- AFAIK, > neither is. > > I also included another trivial patch which adds the default location > of the DSSSL stylesheets on my system (Debian unstable, docbook-dsssl > 1.76) to the list of paths that configure looks for. > > Cheers, > > Neil > > -- > Neil Conway <neilconway@rogers.com> > PGP Key ID: DB3C29FC [ Attachment, skipping... ] [ Attachment, skipping... ] > > ---------------------------(end of broadcast)--------------------------- > TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 853-3000 + If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania 19026