Forum Discussion

prouser's avatar
prouser
Contributor
12 years ago

How to Ignore table name in JDBC response?

Hi All

The JDBC response in the test step is being displayed with the following label names: <tablename.columnname>

But I want to get rid of the table name and just have the column name displayed since the table name is creating a problem with the xpath assertions in my following soap Request test step;as Im data-driving my test and hence query different tables in the JDBC test step and the table name changes everytime but I want the assertions to be made irrespective of the table and only based on the column name

How can I achieve this?
  • Looks like Soap UI Pro 4.6.4 supports Xpath 2.0 which has the "endswith" function

    So, I used the following to get my desired result of ignoring the table names during my assertions

    ${JDBC Request TestStep#ResponseAsXml#//Results[1]/ResultSet[1]/Row[1]/*[ends-with(name(), 'AMOUNT')]}