RE: Select on empty table
Posted in 2000
William Rice <ricew@operamail.com> wrote: >Some things you might try if you like. > >Put your query into that program I sent you, and see what the status >is. I was in the process of doing that when I saw this reply. Strip out everything but the select and the status displays..... Works fine outside of the program. Sooo.... (sound of creaking gears) I had added several other displays between the select and the evaluation in the if statement to diagnose another problem I was having. Did a cut and paste to move them below the if statement and the program works (even though the first display after the if still shows status is 0 -- it appears that any code between the sql and the evaluation of status is enough to set status to 0. Strange since the manuals seem to indicate that status reflects a value associated with the last sql statement. I took that to mean the status variable kept that value until another sql statement reset it. This is the first time I've run across this. As a rule I evaluate status immediately (and usually set a variable based on the outcome). If the code hadn't bombed, the displays wouldn't have gone in and I'd be none the wiser. Thanks to all for the assistance. >If that doesnt work create an empty table and try... > >(I am assuming you ran the one I sent you to make sure your version >of 4gl works the same as mine...) Yep. > >Will carlos Currently on hiatus from unemployment. ---------------------- Do you do Linux? :) Get your FREE @linuxstart.com email address at: http://www.linuxstart.com