0

I have an InfoMaker report that gets results from a stored procedure, but this procedure stalls for a few seconds (intentionally) before returning the result set. When I run and view the report, this causes the PowerBuilder application to freeze until the procedure returns.

I have seen other reports that take a long time to run display a status bar inside the application before the procedure completes and the report is displayed. Is there something I should do in my InfoMaker report or T-SQL procedure to make this happen?

NReilingh
  • 1,730
  • 17
  • 32
  • So if you remove the intentional 'stall' does it work fine? – Matt Balent Apr 07 '15 at 11:23
  • Yep, because the procedure completes in a couple seconds. It "works" with the stall in there, too--it just hangs the app until the procedure returns, which can be up to a minute after starting. A workaround is to run the report "in a new window" so it spawns a new app process, but this still doesn't get me a progress bar. – NReilingh Apr 07 '15 at 11:34

1 Answers1

1

Normally, once the DW has retrieved the first row, the DW control becomes asynchronous - meaning will allow interference manually or by program. If you want to make the window responsive, before connecting to the DB, set the SQLCA.DBParm property to Async=1. This will make the DW and the Window responsive.

If you have a status bar, you can use the timer event to update the status bar with whatever text you want to display there. Like "Pulling the data in 10s..." and then doing a count down using the timer event.

chandru
  • 46
  • 5