Forum Discussion

OleksandrNone's avatar
OleksandrNone
Regular Visitor
2 years ago

How to send empty value from xml (jdbc response) in Property transfer?

Hello, please help with property transfer step.

If response of JDBC request contains any tag with text (for example, <description>Text</description>), I can use property transfer step to send value "text" to my next steps ("Transfer text content" checkbox)

But if this tag is empty (like <description/>, property transfer step sends full tag name (even if checkbox "Transfer text content" is enabled). How can I send empty value in this case?

Thank you

1 Reply

  • richie's avatar
    richie
    Community Hero
    Hey OleksandrNone,

    Do you want your teststep to be able to handle both empty elements and populated ones, or do you know from your test setup if youre gonna get an empty element or not?
    Is this a looping testcase or just a single execution testcase?
    Could you alter your query filter to only return populated tags?
    Rather than a direct transfer you can transfer to a Properties step and then use groovyscript to manipulate the values extracted if needed

    If you can provide more background around what you need, forum users should be able to help

    Cheers,

    Rich