开发者

websphere, SQL1103: Position 24 Column definitions for table STVRECONWK in QTEMP not found

I have a table that is created and then deleted at the end of an SQLRPGLE program

     //Delete the temporary table
     shell('DLTF FILE(QTEMP/STVRECONWK)':IGNORE_ERROR);

     // create 开发者_开发技巧temporary table
     exec sql
       create table qtemp/stvreconwk (
         sysid integer,
         barcode varchar(100),
         description varchar(100),
         matchflag char(1)
       )
     ;

Whenever I try to compile from WebSphere I get

SQL1103: Position 24 Column definitions for table STVRECONWK in QTEMP not found.

The problem is that the table does not exist, if I create the table from a terminal session and then compile (from the terminal also) it works becuase the compiler is able to validate the table as they are running in the same job.

How can I do this in WebSphere?


A file that is created in QTEMP yet is also accessed as an "externally-described" file by the compiler should be created as a duplicate of a 'model' file. Any program that needs to reference the external file description should be compiled to reference the 'model' file that should always exist. The 'model' provides all necessary attributes for the compiler. An override provides access to the duplicate for the program at run-time. The 'model' is just a file description that resides in a library in the library list at compile-time.

With recent versions of the compiler, an override isn't necessary. For RPG, the F-spec can include the EXTDESC() or the EXTFILE() keyword to note either the 'model' file or the run-time file.

In most cases, the 'model' would be duplicated to a QTEMP file using a different name to avoid conflicts.


By Default the WebSphere will run each command in a new job. You can change this in window->preferences->iseries->command execution and uncheck 'compile in batch'

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜