Stored Procedures and running them from 4GL
Posted in 1993
Hi all, Could anyone using Stored Procedures out in Net Land please help with a problem I am having. If anyone has any ideas I will be eternally grateful and I might even spring for a beer (This offer does come with some restrictions - The idea has to to help solve the problem and I wont accept ideas along the lines of "commit suicide" which though it may solve the problem for me isn't really very helpful!!). Now having tried to bribe the net, unnecessary as you are all good, honest people, here is the problem. 4GL program Pcode or executable (4GL V4.10.UE2, Online 5.0.UC5, HP9000/857 running HPUX 8.02) Main Module calls two others 1st Module calls 3 Stored Procedures doing a Prepare and Declare and then Open Fetch Close 2nd Module Prepares Declares some unrelated cursors on views of the database. These views do not access the same tables as the stored procedures. One of the cursors may need to be on a temporary table. Depending on how the code is written we have received either -254 or -363 errors on the Open statements of these cursors. Removing the Open/Fetch/Close of ANY ONE of the Stored Procedures has the effect of making the code run through with no errors which is the expected result with this simple code fragment. A couple of other points. It is not necessarily the next Open cursor statement that generates the error often it is several open statements later. The original program that generated the program was very large was working successfully until we introduced the module containing the Store Procedures. The error came up considerably later in the code!! What I have described above is the small amount of code we are now down to which still generates the error. We are working closely with Informix who have been extremely helpful, but both sides are now running out of ideas. Our next step is to try with the latest release of Online 5.01UD3. If anyone has seen the same problem I would like to hear from you. Any suggestions for a work round for the problem would also be extremely helpful. We could revert back to using pure 4GL but we expect a performance hit if we do this as the data has to be transferred to the front end process rather than processed in the engine. Thanks - Jim My opinions are my own. They may vary with time but they remain MINE! ---------------------------------------------------------------------- Name: Jim Gordon Internet: jgordon@ssf-sys.DHL.COM Company: DHL Systems Inc Phone: (415) 375-5222 (Work) Address: 700 Airport Blvd. #300 (415) 882-9728 (Home) Burlingame, CA 94010-1937 Fax: (415) 375-5019 ----------------------------------------------------------------------