From oracle-l-bounce@freelists.org Thu Apr 28 21:49:16 2005 Return-Path: Received: from air891.startdedicated.com (root@localhost) by orafaq.com (8.12.10/8.12.10) with ESMTP id j3T2nGAK013612 for ; Thu, 28 Apr 2005 21:49:16 -0500 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 j3T2nG4Z013607 for ; Thu, 28 Apr 2005 21:49:16 -0500 Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id DA931186E60; Thu, 28 Apr 2005 20:46:47 -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 10429-10; Thu, 28 Apr 2005 20:46:47 -0500 (EST) Received: from turing (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id D33931891DA; Thu, 28 Apr 2005 20:46:34 -0500 (EST) Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; b=qqVXG7P95H+7wdcf9t7hajVXYhsbqyrCrMtEVm8mFMWtZNAm4CGuLyJ8rZAzsP2MIJmQjoCb9p4UUsT9VoHPQO7VOCDL2uXgrGqlSiZoHk7oPSOuf4jwPKiWMT8us79hutXrge2h9gF2MHhLS5bHkPRkA5ZAr3WqVJxzBV93/9E= ; Message-ID: <20050429014432.40628.qmail@web51304.mail.yahoo.com> Date: Thu, 28 Apr 2005 18:44:32 -0700 (PDT) From: Sanjay Mishra Subject: SQl Query Help To: oracle-l@freelists.org MIME-Version: 1.0 Content-type: text/plain Content-Transfer-Encoding: 8bit X-archive-position: 19176 X-ecartis-version: Ecartis v1.0.0 Sender: oracle-l-bounce@freelists.org Errors-To: oracle-l-bounce@freelists.org X-original-sender: smishra_97@yahoo.com Precedence: normal Reply-To: smishra_97@yahoo.com X-list: oracle-l X-Virus-Scanned: by amavisd-new-20030616-p9 (Debian) at avenirtech.net X-Spam-Level: * X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on air891.startdedicated.com X-Spam-Status: No, hits=1.5 required=5.0 tests=AWL,FORGED_YAHOO_RCVD, FROM_ENDS_IN_NUMS autolearn=no version=2.63 Hi I am looking one query help and below is scenario Table A contains FatherId ChildId A Father can have several Children Table B contains ChildId DateOfBirth Now I need the output as Fatherid and its ChildId only and only if all of it Child are born in some TimeFrame. If any of the Child is born out of this TimeFrame then it will ignore all of those FatherId and ChildId. e.g TableA FatherId ChildId 1 1,2,3, 2 8,9,10 3 11,12 TableB ChildId DOB 1 jan 03 2 Jul 04 3 Aug 05 8 Jan03 9 Jan 04 10 jan 05 11 Feb 04 12 Dec 04 Now I am looking TimeFrame of Jan1 04 to Dec 31 04 So it should display only FatherId ChildId DOB 3 11,12 Feb04 and Dec 04 As all other Father 1 and 2 have some child born in 03 or 05 Thanks for your help __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com -- http://www.freelists.org/webpage/oracle-l