Re: How do I determine the row number or key when table has no key fields

2004-04-12 Thread Kevin Carlson
Andy Ford wrote: I thought LIMIT limited you to N number of CONCURRENT record. ie. limit 10 or limit 20 I believe Ross would like to select select 1000 records and then do a sub select of records 1-20 and then 21-40 on this record set LIMIT also allows you to specify a starting record, i.e. LIM

RE: How do I determine the row number or key when table has no key fields

2004-04-02 Thread Andy Ford
I thought LIMIT limited you to N number of CONCURRENT record. ie. limit 10 or limit 20 I believe Ross would like to select select 1000 records and then do a sub select of records 1-20 and then 21-40 on this record set Or am I barking up the wrong tree? Andy On Fri, 2004-04-02 at 14:05, Andy Eas

RE: How do I determine the row number or key when table has no key fields

2004-04-02 Thread Andy Eastham
Ross, You'll need to do an order by on both columns (so you'll need to index both columns in a compound index), then use the LIMIT keyword which is designed for exactly this job. Alternatively, unload the data using mysqldump, then edit the table definition to have an autoincrement column, then r

Re: How do I determine the row number or key when table has no key

2004-04-02 Thread Terry Riley
Take a look at LIMIT in the Manual Cheers Terry --Original Message- > eg. say a table is created using: > > create table fred (f1 char(10), f2 int) > > Then it has neither keys nor an AUTO_INCREMENT field. > > Let's say 1000,000 records are then inserted into table fred