Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Sorting a sheet by a column in POI

 
Radha MahaLakshmi
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All

I need to extract data from an excel for furtha processing.
I am using POI to extract the data and i could able to do it successfully.
I want to know is there any way we can sort the sheet by a column through POI.

Thanks and Regards
Radha
 
Ashish Vegaraju
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,

i too worked on POI, but i m not getting what u want to say..can u explain it in detail?
Ashish.
 
Stan James
(instanceof Sidekick)
Ranch Hand
Posts: 8791
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As an alternative approach, on Windows you can open a spreadsheet as a database and a named range as a table with JDBC-ODBC drivers. You should be able to do a standard query with order by in that case.
 
Radha MahaLakshmi
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Thanx for the reply.
My application needs to be deployed on UNIX.

Is there anyway i can sort on a column of spread sheet through java using POI.

Regards
Radha
 
Karthikeyan Rajendraprasad
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
no direct method is there i hope. instead you can write a simple ascending/descending order program base on the column type.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic