> that's strange on 9.0.1 the ORDER BY on the inner SELECT works like it > should.
Well, Oracle introduced this feature of using "inline views" with release 8.1.6. Previous versions don't understand this syntax. > Could you add a comment to bug 1199 about this behavier. OK, I didn't yet know about this old bug entry. Regards, Martin > ----- Original Message ----- > From: "Martin Fuchs" <[EMAIL PROTECTED]> > To: "castor-dev" <[EMAIL PROTECTED]> > Sent: Saturday, October 02, 2004 2:46 AM > Subject: [castor-dev] Re: Verify SQL syntax of LIMIT clause on Oracle > version prior to 8.1.6 > Hi Ralf, > > Hi castors, > > do anyone have an Oracle server with version prior to 8.1.6 (e.g. 8.0.x or > > 7.x) runing and can try if the following query can be executed. > Yes, it (partly) works for 8.0.5 dbs: > SELECT * FROM ( > SELECT t1.*, rownum rnk FROM ( > SELECT * FROM emp > ) t1 > ) WHERE rnk BETWEEN 5 AND 7 > / > It returns for example: > 7654 MARTIN SALESMAN 7698 28.09.2081 00:00:00 1250 1400 30 5 > 7698 BLAKE MANAGER 7839 01.05.2081 00:00:00 2850 30 6 > 7782 CLARK MANAGER 7839 09.06.2081 00:00:00 2450 10 7 > The problem is, you can't put an ORDER BY clause in the inner SELECT. > It would only be allowed in the outer SELECT, which is not really, what we > want here. > The sorting should occure before the filtering. > Regards, > Martin
----------------------------------------------------------- If you wish to unsubscribe from this mailing, send mail to [EMAIL PROTECTED] with a subject of: unsubscribe castor-dev