i want o know the steps involved in testing a DATABASE using QTP 9.2.
thanks in advance!!!
raj
Printable View
i want o know the steps involved in testing a DATABASE using QTP 9.2.
thanks in advance!!!
raj
For doing database validation using QTP you have to do the following
a. Insert database check points to validate the records as per the specifications
b. You can write the SQL queries in QTP to do the retrieval, insertion, updation or deletion of records.
c. QTP scripts has to be written along with the SQL queries for doing database testing
Hi Raj,
Database testing using QTP would look something like this -
[U]DSNLess[/U]
dim sCon
dim sRec
set sCon = CreateObject("ADODB.Connection")
sCon.Provider = "Microsoft.Jet.OLEDB 4.0"
sCon.connectionString = "DataSourceName = ;UserId = ;Pwd = ;InitialCatalog="
sCon.Open
set sRec = CreateObject("ADODB.Recordset")
sRec.Open "Select * from Table_Name {Conditions}",sCon, adOpenDynamic
Get the individual values stored in sRec using a for loop.
sRec.fields(0) - would fetch the first value stored in the sRec Object.
Cheers.....