# Test Enhancement Proposal

**URL:** <https://techcommunity.softwareag.com/t/test-enhancement-proposal/57651>\
**Category:** Forum\
**Created:** [April 25, 2007, 8:23pm UTC](https://techcommunity.softwareag.com/t/test-enhancement-proposal/57651 "2007-04-25T20:23:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 25, 2007, 8:23pm UTC](https://techcommunity.softwareag.com/t/test-enhancement-proposal/57651/1 "2007-04-25T20:23:00Z")

</div>

1 Task  
A program has to read data from the database and present these in a map. The data should be read again and presented in the same map after a certain period, So that the map displays the time varying data in a certain frequence. This can be accomplished utilising the non-conversational mode - statement SET CONTROL ‘N’ - and user exit USR2027 to wait a some seconds.

2 Problem  
After the process is initiated the map cannot accept any user interaction because of SET CONTROL ‘N’. The task has to be terminated in order to finish the program - see appendix for sample.

3 Workaround  
The only way to get the process stopped properly is to evaluate a database field as an indicator. The example shows how to get this done. Program BEISPIEL starts to display data in a certain frequency without user interaction. It cannot be stopped from the same task so it uses an indicator which has to be set from another Natural session executing program BSPEND.

4 Proposal  
A task should be able to wait a certain time for some defined user interaction and should react on it if it happened. If not it should work as with SET CONTROL ‘N’. The sequence should be

1. Wait for INPUT
2. Was some INPUT entered?  
Yes: Process the INPUT  
No: Do the next non-coversational step
3. Go to 1

See download for example program  
[EP3272.txt](https://techcommunity.softwareag.com/uploads/short-url/fMmooaIZ5eCxFwz5UzTbTmRYE6u.txt) (2.65 KB)

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 25, 2007, 8:23pm UTC](https://techcommunity.softwareag.com/t/test-enhancement-proposal/57651/2 "2007-04-25T20:23:42Z")

</div>

Hello,

you can use the   
TXMLObjectAccessor.query( TQuery query, int quantity) method, it makes use of a Tamino cursor.

WARNING: this can only be used in a local transaction mode !!!

With TResponse.getXMLObjectIterator() you can iterate easy in your result set.

Cheers, Andi

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 2:38pm UTC](https://techcommunity.softwareag.com/t/test-enhancement-proposal/57651/3 "2021-04-02T14:38:47Z")

</div>


