Results 1 to 4 of 4
  1. #1
    Join Date
    Aug 2002
    Posts
    2

    Cool Unanswered: system Command in store procedure

    I tried to use a store procedure to launch 4ge program and got the following error message:

    -668 System command cannot be executed. A system call failed in the operating system. The following example shows a statement that might cause an error: SYSTEM
    'hello';

    -1 Not owner. An operating-system error code with the meaning shown was unexpectedly returned to the database server. Check the ownership and permissions of files and directories that are used in the current operation. Look for other operating-system error messages that might give more information.

    I can launch 4ge program from command line without any problem, and the attribute for the 4ge program is :-rwxrwxrwx.

    Any idea?

  2. #2
    Join Date
    Aug 2002
    Location
    Belgium
    Posts
    534
    The system command will be executed by the user who started the informix server.
    ps -ef |grep oninit will show you that user.

    Make sure your 4GL executable has execute permissions for this user.
    rws

  3. #3
    Join Date
    Aug 2002
    Location
    Belgium
    Posts
    534
    woeps, sorry about that quick response...
    Check the following file: system.txt
    Attached Files Attached Files
    rws

  4. #4
    Join Date
    Aug 2002
    Posts
    2
    Thanks.
    Finally, It looks like I solved the problem.
    1. when the 4ge program is called by system comand, the environment is different.
    some env variables are missing, for example, INFORMIXDIR, INFORMIXSERVER, and LIBPATH.
    The command line should set those env variables.

    2. Then, The store procedure should use the c shell script to launch the 4ge program. In the script file, redirect the error message to a file.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •