But.. Can i get sort one column by descending and the other ascending. say if i have two columns and first i would like to sort the one in ascending and then sort the second column based on the search from the first.
I mean I i have 1 5 2 6 1 8 2 9 Could i get an output as 1 5 1 8 2 6 2 9 Sorry to restart the thread. Thanks Sree aurovindhV On Thu, Mar 22, 2012 at 10:09 PM, Francesc Alted <fal...@gmail.com> wrote: > On 3/22/12 11:02 AM, sreeaurovindh viswanathan wrote: >> Hi, >> >> If I have three columns in a table and if i wish to sort based on one >> field and then on the other what would be the recommended method.I >> would be sorting atleast 75,00,000 records at a time. >> >> ie I would like to use something equivalent the following sql query. >> >> Select * from sample.table order by query desc,keyword asc. > Provided that you have created a CSI index on this field, there are a > couple of ways for doing this: > > 1) Table.itersorted(): retrieves the table records in sorted order > > 2) Table.readSorted(): retrieves the complete sorted table as a > monolithic structured array > > Both methods follow ascending order by default. Choose a step=-1 for > choosing a descending order. > > -- Francesc Alted > > ------------------------------------------------------------------------------ > This SF email is sponsosred by: > Try Windows Azure free for 90 days Click Here > http://p.sf.net/sfu/sfd2d-msazure > _______________________________________________ > Pytables-users mailing list > Pytables-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/pytables-users ------------------------------------------------------------------------------ This SF email is sponsosred by: Try Windows Azure free for 90 days Click Here http://p.sf.net/sfu/sfd2d-msazure _______________________________________________ Pytables-users mailing list Pytables-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/pytables-users