IBM Support

IT28752: CREATE SP INCLUDING A CREATE FUNCTION STATEMENT FAILS IN GETVARTYPE INSTEAD OF RETURNING A -201

Subscribe to this APAR

By subscribing, you receive periodic emails alerting you to the status of the APAR, along with a link to the fix after it becomes available. You can track this item individually or track all items by product.

Notify me when this APAR changes.

Notify me when an APAR for this component changes.

 

APAR status

  • Closed as program error.

Error description

  • The following esql/c program
    
    
    $include sqlca;
    
    #include <stdio.h>
    
    main()
    {
    $char buffer[600];
    
    $drop database b;
    $create database b;
    
    sprintf ( buffer, " create procedure create_function_in_sp()
    DEFINE GLOBAL gl_trace SMALLINT DEFAULT 0;     IF (gl_trace = 1)
    THEN       TRACE ON;    END IF; CREATE FUNCTION
    get_genr_alias_doc_st(pPb_Num INTEGER, pSub_id SMALLINT, PDoc_St
    CHAR(3), pI_code CHAR(5))      RETURNS CHAR(6)       return
    get_genr_alias_doc_st(pPb_Num, pSub_id, PDoc_St, pI_code) ;
    END FUNCTION ;  END PROCEDURE" );
    
    $prepare p1 from :buffer;
    printf( " %d \n ",sqlca.sqlcode );
    $execute p1 ;
    printf( " %d \n ",sqlca.sqlcode );
    }
    
    
    creates an af file with the stack
    
    0x0000000001331ae6 (oninit) afstack
    0x0000000001338cac (oninit) mt_ex_throw_sig
    0x00000000012df593 (oninit) afsig_handler
    0x00007f00bae71b10 (Linux) <signal frame>
    0x000000000064b2df (oninit) getvartype
    0x0000000000819d39 (oninit) gettypeexpr
    0x0000000000640039 (oninit) op_bind_rtn
    0x00000000006391fc (oninit) buildexpr
    0x000000000063c9b4 (oninit) expr2expr
    0x000000000064cd6e (oninit) ip_bldsexpr
    0x0000000000656138 (oninit) dcmpbody
    0x0000000000657c55 (oninit) decompile_proc
    0x00000000006772e4 (oninit) retrieve_cache
    0x000000000069962e (oninit) udr_getbyid_uid
    0x000000000069a820 (oninit) udr_dropid
    0x00000000006718ee (oninit) pr_compile
    0x00000000009787bd (oninit) creatproc
    0x0000000000689a6e (oninit) aud_creatproc
    0x00000000005aefb2 (oninit) excommand
    0x00000000009b32ac (oninit) sq_execute
    
    
    running the same statement in dbaccess will return an error
    -201.
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * Users of IDS prior to version 14.10.xC2.                     *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * A create procedure statement that includes a create function *
    * statement fails in getvartype instead of returning a -201    *
    * syntax error.                                                *
    ****************************************************************
    * RECOMMENDATION:                                              *
    ****************************************************************
    

Problem conclusion

  • Fixed in IDS 14.10.xC2.
    

Temporary fix

Comments

APAR Information

  • APAR number

    IT28752

  • Reported component name

    INFORMIX SERVER

  • Reported component ID

    5725A3900

  • Reported release

    C10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2019-04-11

  • Closed date

    2019-09-20

  • Last modified date

    2019-09-20

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    INFORMIX SERVER

  • Fixed component ID

    5725A3900

Applicable component levels

[{"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSGU8G","label":"Informix Servers"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"C10","Edition":"","Line of Business":{"code":"","label":""}}]

Document Information

Modified date:
20 September 2019