From oracle-l-bounce@freelists.org Tue Mar 8 08:53:07 2005 Return-Path: Received: from air891.startdedicated.com (root@localhost) by orafaq.com (8.12.10/8.12.10) with ESMTP id j28Er7QS031171 for ; Tue, 8 Mar 2005 08:53:07 -0600 X-ClientAddr: 206.53.239.180 Received: from turing.freelists.org (freelists-180.iquest.net [206.53.239.180]) by air891.startdedicated.com (8.12.10/8.12.10) with ESMTP id j28Er7em031167 for ; Tue, 8 Mar 2005 08:53:07 -0600 Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id BB2B37EF1D; Tue, 8 Mar 2005 08:51:35 -0500 (EST) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 07541-05; Tue, 8 Mar 2005 08:51:35 -0500 (EST) Received: from turing (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 43F917EF58; Tue, 8 Mar 2005 08:51:35 -0500 (EST) Message-ID: X-Originating-IP: [204.101.196.18] X-Originating-Email: [ganstadba@hotmail.com] X-Sender: ganstadba@hotmail.com From: "Michael McMullen" To: , References: <6292852314.20050307233330@gennick.com> Subject: Re: Hotsos Symposium, Day 1 Date: Tue, 8 Mar 2005 08:48:17 -0500 MIME-Version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 X-OriginalArrivalTime: 08 Mar 2005 13:49:52.0947 (UTC) FILETIME=[B44EC030:01C523E5] X-archive-position: 17054 X-ecartis-version: Ecartis v1.0.0 Sender: oracle-l-bounce@freelists.org Errors-To: oracle-l-bounce@freelists.org X-original-sender: ganstadba@hotmail.com Precedence: normal Reply-To: ganstadba@hotmail.com X-list: oracle-l X-Virus-Scanned: by amavisd-new-20030616-p9 (Debian) at avenirtech.net X-Spam-Checker-Version: SpamAssassin 2.60 (1.212-2003-09-23-exp) on air891.startdedicated.com X-Spam-Status: No, hits=0.1 required=5.0 tests=AWL,UPPERCASE_25_50 autolearn=no version=2.60 X-Spam-Level: Read the rest of the blog, it gives the solution for the problem you listed. ----- Original Message ----- From: "Thomas Day" To: Sent: Tuesday, March 08, 2005 8:28 AM Subject: Re: Hotsos Symposium, Day 1 > I tried running the CONNECT BY example that you had. > > SQL> SELECT TRUNC(SYSDATE,'YEAR') + LEVEL - 1 > 2 FROM DUAL > 3 CONNECT BY 1 = 1 > 4 AND LEVEL < TRUNC(SYSDATE+366,'YEAR') - TRUNC(SYSDATE,'YEAR') + 1; > > TRUNC(SYS > --------- > 01-JAN-05 > > 1 row selected. > > I'm obvisously missing something. What's with the 1=1? > > > 1 SELECT TRUNC(SYSDATE,'YEAR') + LEVEL - 1 > 2 FROM DUAL > 3 CONNECT BY > 4 --1 = 1 AND > 5* LEVEL < TRUNC(SYSDATE+366,'YEAR') - TRUNC(SYSDATE,'YEAR') + 1 > SQL> / > > TRUNC(SYS > --------- > 01-JAN-05 > > 1 row selected. > -- > http://www.freelists.org/webpage/oracle-l > -- http://www.freelists.org/webpage/oracle-l