What are the details steps to connect a remote mysql
database in QTP



What are the details steps to connect a remote mysql database in QTP..

Answer / santhosh ankam

This is code to run sql query through qtp.

SQL "SELECT * FROM ORDERS"
connection_string "QT_Flight32"
columns 1
set connection CreateObject("ADODB.Connection")
connection.Open connection_string
set rs1 connection.Execute( SQL )
rows db_get_rows_count(rs1)
msgbox rows
rows rows-1
myval db_get_field_value(rs1 rows columns )
msgbox myval

Is This Answer Correct ?    1 Yes 8 No

Post New Answer

More QTP Interview Questions

i this is balaji from chennai i have 4 yrs exp in testing and my qualification is bsc computers i completed in correspondace in which companiies accept the correspondace plz let me know

1 Answers   Accenture,


what is supply chain management?

0 Answers   ITC Infotech,


Please have a look at this: a = Browser("Travel Boutique Online").Page("Travel Boutique Online_2").webelement("innerhtml:=2622").getroproperty("y") a=a+9 msgbox a Browser("Travel Boutique Online").Page("Travel Boutique Online_2").image("alt:=check","y:=a").click Now please let me explain. As clear from code I am trying to enter value of variable 'a' as Property y. But each time QTP AND MY SYSTEM stops responding when this line is execcuted. But When i enter some number in place of 'a' in the last line. it works fine. Please let me know what I am doing wrong at time of entering the variable in last line. Thanks a lot

3 Answers  


Wht are the BY default Add-ins in QTP 9.2 version and what all are differences between 8.2 and 9.2

2 Answers   Siemens,


what is the hierachy of Descreptive programming?

3 Answers   Fiserv,






How can I find out the cursor position through QTP suppose I am keep tabbing(Pressing the tab key continuously) and stoped at a position Now I want to find out where the cursor position is

0 Answers   HP, Livetek,


How to compare the two strings?

2 Answers  


i have to pass the testcases into userid anf password of gmail login page using functions you can take your own testcaseslike userdid should take only lowerletters it should not take special charactors and uppercase letters and password should take only numericvalues it should not take alphanumeric and alphabets

2 Answers  


Hi friends, In a particular test how many maximum call to new actions we can call?It reusable or normal actions what ever it is .

1 Answers   AppLabs,


what is vss and cvs what is main difference b/w these two

3 Answers  


• Re –Engineering the regression testing from 0% to 60% automation. This has saved 4-mandays in every release. what doeas this statement means

2 Answers   Infosys,


What are the technics follow in writing VB script?

0 Answers   CTS,


Categories