Geeks Talk

Prepare for your Next Interview


Welcome to the Geeks Talk forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

comparing huge amount of data with .xls

This is a discussion on comparing huge amount of data with .xls within the QTP forums, part of the Software Testing category; i have a task of comparing two data sheet with hundreds of rows and columns using QTP...plz can anybody suggest a test scenario on whats the shortest way to do ...

Go Back   Geeks Talk > Software Testing > QTP
Register Blogs FAQ Tag Cloud Calendar Mark Forums Read
  #1 (permalink)  
Old 09-06-2008
Junior Member
 
Join Date: Aug 2008
Location: chicago
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
danaasady is on a distinguished road
comparing huge amount of data with .xls

i have a task of comparing two data sheet with hundreds of rows and columns using QTP...plz can anybody suggest a test scenario on whats the shortest way to do it?


dana
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 09-08-2008
Expert Member
 
Join Date: Jan 2007
Location: India
Posts: 208
Thanks: 3
Thanked 19 Times in 19 Posts
NawabShaikh is on a distinguished road
Re: comparing huge amount of data with .xls

If both the data sheets contains data in similar format just a nested loop is required.

1. CreateObject("Excel.Application")----twice as u have two xls.

2. Loop for Cell data nested loop considering xls as a 2 -dimensional array.


regards,
Nawab
Reply With Quote
  #3 (permalink)  
Old 09-08-2008
Contributing Member
 
Join Date: Sep 2006
Location: CHENNAI
Posts: 48
Thanks: 5
Thanked 4 Times in 4 Posts
gokulakrishnan_k is on a distinguished road
Re: comparing huge amount of data with .xls

Hi,

1.Open the two XL sheets.XL1 and XL2

2.Check both the row counts are same or not.

3.Compare the values of XL1 with and XL2

4.Store the values along with result in run time datatable.

5. Close the test.

Thanks

G K
Reply With Quote
  #4 (permalink)  
Old 09-08-2008
Expert Member
 
Join Date: Jan 2007
Location: India
Posts: 208
Thanks: 3
Thanked 19 Times in 19 Posts
NawabShaikh is on a distinguished road
Re: comparing huge amount of data with .xls

Set oXL = CreateObject("Excel.Application")

oXL.Workbooks.Open "path"
''the First Worksheet element
val1 = oXL.WorkSheets(SheetName).Cells(RowNumber, ColNumber)
''Second Worksheet element
val2 = oXL.WorkSheets(SheetName).Cells(RowNumber, ColNumber)

The Above cove can be used in loop assuming that the worksheets are in the same XLS, else CreateObject for another excel.

Regards,
Nawab

Last edited by NawabShaikh; 09-08-2008 at 03:40 AM. Reason: Spell Check
Reply With Quote
  #5 (permalink)  
Old 09-08-2008
Junior Member
 
Join Date: Aug 2008
Location: chicago
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
danaasady is on a distinguished road
Talking Re: comparing huge amount of data with .xls

thank you very much Nawab and the other guys..u guys turned on the light bulb on top of my head
Reply With Quote
Reply

  Geeks Talk > Software Testing > QTP

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
Comparing Two Job Offers admin Site News & Announcements 0 04-22-2008 08:50 PM
Huge interest in business techtalk Career Advice 1 10-03-2007 08:31 AM
I have a task of comparing the huge piece of data Geek_Guest QTP 1 08-21-2007 06:45 AM
I need to update huge amount of data into oracle database. Geek_Guest Oracle 1 06-25-2007 03:02 AM
How do we access 4 elements in a huge XML Doc Geek_Guest AJAX & XML 0 06-05-2007 09:27 PM


All times are GMT -4. The time now is 08:26 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.1
Copyright © 2009 GeekInterview.com. All Rights Reserved