Micro Focus QTP (UFT) Forums
Multiple Data Set With Different Child Data Set - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: Multiple Data Set With Different Child Data Set (/Thread-Multiple-Data-Set-With-Different-Child-Data-Set)



Multiple Data Set With Different Child Data Set - Suba - 03-25-2011

Hi,

I am new with QTP and self learning this tool.

Need help while I am trying to visualize a process to setup a test with many reusable actions which will primarily receive paramitized data feed through datatable.

My dilemma is how to setup the process and it's data that can handle multiple data set, each having different child data set.

For Example: Hierarchy of an Auto Policy Insurance data will look as below:
Policy Deatils (Includes number & other Policy level Info.)
|
-->Vehicle Information (Includes each Vehicle level Info.)
|
--> All Coverages Information (Which could differ bewteen each Vehicles within the Policy)
|
--> Driver information (Includes all Drivers Info associated with each vehicle)

How can I setup the data and the process if I want to have a Single test with reusable actions such that the test can handle Multiple Policies with corresponding Vehicle, Coverages and Driver information?

Looking for your suggestions and thanks in advance.
Subha





RE: Multiple Data Set With Different Child Data Set - basanth27 - 04-01-2011

Suba,
You can columnize the excel to have action names and the rows to contain data respective to the actions.

Let me potray the logic,

1. Loop through the sheet to pick the values.
2. Create Reusable actions with Input and output action parameters.
3. feed the values from the datatable on to the input action parameters.

Your Test might look something similar to this,
Code:
For x=1 to totalrows
Runaction "ACtionName", Param1, Param2 etc
Runaction "ACtionName", Param1, Param2 etc
Runaction "ACtionName", Param1, Param2 etc
Next

Or you can perform the same on a case basis controlling the execution of the action.
Code:
Select(Case)
Case : ACtionDriver
Runaction "ACtionName", Param1, Param2 etc
Case: ACtionInsurance
Runaction "ACtionName", Param1, Param2 etc
End Select

It is very rustic at the moment. Please spend sometime to enhance it and if you face issues we can chisel in then.[/code]


RE: Multiple Data Set With Different Child Data Set - Suba - 04-08-2011

Thanks Basanth. I will give a try.

Alternatively, using the looping mechanism, can I switch the datatable for each Policy data and it corresponding Vehile, coverages and drivers?

Thanks,
Subha