RE: Nested MySQL Statements

2002-12-14 Thread Adolfo Bello
Not until version 4.1 > -Original Message- > From: Peter Vertes [mailto:[EMAIL PROTECTED]] > Sent: Friday, December 13, 2002 8:43 AM > To: MySQL Help List (E-mail) > Subject: Nested MySQL Statements > > > Hello All, > > Is it possible to do neste

re: Nested MySQL Statements

2002-12-14 Thread Egor Egorov
On Friday 13 December 2002 14:43, Peter Vertes wrote: > Is it possible to do nested select statements with MySQL ? Basically > I'm trying to display the last 5 rows that got inserted into a table. My > SQL query looks like this: > > select * from tablename limit ((select count(*) from tablen

Nested MySQL Statements

2002-12-14 Thread Peter Vertes
Hello All, Is it possible to do nested select statements with MySQL ? Basically I'm trying to display the last 5 rows that got inserted into a table. My SQL query looks like this: select * from tablename limit ((select count(*) from tablename) - 5), -1; In theory it works for me :) b