Submit and vote on feature ideas.

Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.

Sql query

Options

I used sql query to fetch the data count from data base and i want to validate the count is matching with data file count i have.
Can anyone suggest me how to do using soa tool

Answers

  • benken_parasoft
    benken_parasoft Posts: 1,235 ✭✭✭
    edited September 2023
    Options

    Are you using SOAtest's DB Tool? The DB Tool has an output which returns the SQL result set as an XML document. You can chain an XML Assertor tool to make any assertions on the results.

    In this particular case, it sounds like you could configure an "Occurrence Assertion" on the "row" element. Make sure you select "Apply to all row[*]". You can then set "Occurrences of element" to whatever number you expect. The expected value can also reference an existing test variable or data bank column or can be scripted if needed.