Saturday, April 18, 2015

About Capital Market

Financial markets can be categorized into two types. 1.Money markets 2.Capital markets Money markets are the markets through which governments or corporates raise money to meet their short term money requirements (like meeting their working capital requirements). The government, through money markets can raise money for very short periods like 15 days also. Capital markets are the markets through which corporate bodies raise money for their long term needs Capital markets can again be categorise as 1.primary markets 2.Secondary markets

About Capital Market

Financial markets can be categorized into two types. 1.Money markets 2.Capital markets Money markets are the markets through which governments or corporates raise money to meet their short term money requirements (like meeting their working capital requirements). The government, through money markets can raise money for very short periods like 15 days also. Capital markets are the markets through which corporate bodies raise money for their long term needs Capital markets can again be categorise as 1.primary markets 2.Secondary markets

Friday, December 12, 2014

Remove leading 0 from number-formatnumber

Hi

Remove leading 0 from number using QTP. For example 0.09 should display. 09

Strtemp=0.09
Strnew=formatnumber(strtemp,,0)
Msgbox Strnew
'output is . 09

Strtemp=20000
Strnew=formatnumber(strtemp)
Msgbox strnew
'output is 20,000.00

Strtemp=formatnumber(20000,2)
'output 20,000.00
Strtemp=formatnumber(20000,5)
'output 20,000.00000 setting number of decimals
Strtemp=formatnumber(.30,,-1)
'output 0.20 with leading 0
Strtemp=formatnumber(-50,,,0)
'output -50.00 negative value
Strtemp=formatnumber(-50,,,-1)
'output (50.00) negative value inside parenthesis
Strtemp=formatnumber(1000000,,,,0)
'output 1000000.00 not grouping number
Strtemp=formatnumber(1000000,,,,0)
'output 1,000,000.00 grouping number

Monday, December 8, 2014

Working with XML

Accessing XML

Dim StrXmldatafile=c:\test.xml

Set xmldoc=createobject("Microsoft.XMLDOM"")
Xmldoc.async=false

Xmldoc.load(StrXmldatafile)

'get number of nodes
Set nodes=Xmldoc.selectnodes("/bookstore/book")
Msgbox "total books" &nodes.length

'get title of all books
Set nodes=Xmldoc.selectnodes("/bookstore/book/title/text()")
'get their value
For I=0 to ( nodes. Length -1)
Title = nodes(I).nodevalue
Msgbox " title#"&(I+1)&":"&title
Next

'get first book element that is child of bookstore element
Setnodes=xmldoc.selectnodes("/bookstore/book[1]")

'get last book element that is child of bookstore element
Strnodes=xmldoc.selectnodes("/bookstore/book[last()]")

'get all title element that have attribute name Lang
Strnodes=xmldoc.selectnodes("//title[@Lang]")

'get all title element that have attribute name Lang with value English
Strnodes=xmldoc.selectnodes("//title[@Lang='english']")

'get all book element of bookstore element that have price element with value >35
Strnodes=xmldoc.selectnodes("/bookstore/book[price>35.]")

'get all title element of book element of bookstore element that have price element with value > 35
Strnodes=xmldoc.selectnodes("/bookstore/book[price>35.00]/title")

Call dynamic function using QTP/UFT

Hey folks,

Here m explain how to call dynamic function name which is store in variable in UFT 11.5

Strcmd="call " & strfuncname
Execute strcmd

Regards
Trupti

Monday, May 19, 2014

Query to fetch column names

Query to fetch column names
SQL server 2008

Select column_name,*from information_schema.columns where table_name='tblnm' order by ordinal_position

Oracle 11g
Select column_name from all_tab_columns where table_name=upper('tblnm')

Query to fetch table name which use particular column
Select tbname from sysibm.syscolumns where name like '%column_name'

Friday, November 8, 2013

Defect Detection and Prevention Technique


Hey folks,
PFA one nice article on Defect Detection and Prevention.
Defect Prevention  & Defect Detection

       Defect Prevention techniques address how to prevent “error” before it is injected:

      Root Cause Analysis of problem

      Education and training

      Software process maturity and improvement (e.g. CMMI)

       Defect Detection techniques address how to find the faults:

      Testing (with various techniques covered in this class)

      Reviews and inspection

      Formal verification (next lesson)

Cause-and-Effect  Diagram ( for error prevention )