• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

facing diffculties while comparing two excel sheet using poi

 
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi all
i have a task to compare excel sheets,that should be generic,so that at run time it can be any excel file.
i have written a code which checks rows and cells based on which i have written a logic to check one row with other row ie cells in it also.
if they are differnt ,then color with blue in both cells.
if they are same ,color it with common color.
but my problem is if sheet contain empty rows it is not giving proper count ie getPhysicalNumberOfRows(),pSheet.getLastRowNum() which is not counting empty row.
similarly cell if there is a row with cells ie last two cells of a row are empty its showing 1 less count i used both methods but not getting proper cell count ie
.getLastCellNum(),getPhysicalNumberOfCells().

please give me idea for proper row count and cells,where my logic depends on it.

or code snippets to compare to excel sheets.


please give your inputs regarding the above.
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Anish,
I am a QA engineer and i need help in writing java code for comparing two excel reports as part of our automation exercise.
If you can please share your code, that will be really useful to me. The excel reports don't have empty rows, so your original code should work for me.

Thanks in advance,
Savitha
 
anish reddy
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i developed this component some year back.


i am not able to post the source code i developed .
if you want can you post your email id i will send to that.

 
Savitha Srinivasan
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you so much Anish.
My e-mail id is mail2savi@gmail.com.
If you can send the code, that would be really great.
 
Arch enemy? I mean, I don't like you, but I don't think you qualify as "arch enemy". Here, try this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic