Re: Added Having Clause
От | Bruce Momjian |
---|---|
Тема | Re: Added Having Clause |
Дата | |
Msg-id | 199803301636.LAA14220@candle.pha.pa.us обсуждение исходный текст |
Список | pgsql-hackers |
Applied. This adds HAVING to the system, and is our first contribution from Stefan, who is doing his thesis on adding ANSI features to PostgreSQL. (Stefan, correct me if I am wrong on this.) He plans to finish by June. > > Hi! > > I started adding the Having Clause and it works quite fine for > sequential scans! (I think it will also work with hash, index, etc but > I did not check it out! I made some High level changes which should > work for all access methods, but maybe I'm wrong. Please let me know.) > > Now it is possible to make queries like: > > select s.sname, max(p.pid), min(p.pid) > from part p, supplier s > where s.sid=p.sid > group by s.sname > having max(pid)=6 and min(pid)=1 or avg(pid)=4; > > Having does not work yet for queries that contain a subselect statement > in the Having clause, I'll try to fix this in the next days. > > If there are some bugs, please let me know, I'll start to read the > mailinglists now! > > Now here is the patch against the original 6.3 version (no snapshot!!): > > It is encoded using uuencode and called: > postgresql-6.3.tar.gz_to_having.diff.gz.uu > > If your original 6.3 source tree is in: > tmp/postgresql-6.3/ > perform the following steps to apply the patch: > > $ cd tmp/ > $ uudecode postgresql-6.3.tar.gz_to_having.diff.gz.uu > $ gunzip postgresql-6.3.tar.gz_to_having.diff.gz > $ patch < postgresql-6.3.tar.gz_to_having.diff > > Hopefully you will see only "Hunk succeeded..." messages :-) > > Regards > > Stefan > -- Bruce Momjian | 830 Blythe Avenue maillist@candle.pha.pa.us | Drexel Hill, Pennsylvania 19026 + If your life is a hard drive, | (610) 353-9879(w) + Christ can be your backup. | (610) 853-3000(h)
В списке pgsql-hackers по дате отправления: