• unknown's avatar
    Bug#20777 Function w BIGINT UNSIGNED shows diff. behaviour with and without --ps-protocol · ffc605aa
    unknown authored
    - Stored procedures returning unsinged values returns signed values if
      text protocol is used. The reason is that the stored proceedure item
      Item_func_sp wasn't initializing the member variables properly based
      on the information contained in the associated result field.
    - The patch is to upon field-item association, ::fix_fields, initialize
      the member variables in appropriate order.
    - Field type of an Item_func_sp was hard coded to MYSQL_TYPE_VARCHAR.
      This is changed to return the type of the actual result field.
    - Member function name sp_result_field was refactored to the more 
      appropriate init_result_field.
    - Member function name find_and_check_access was refactored to 
      sp_check_access.
    
    
    mysql-test/r/sp.result:
      - Added test
    mysql-test/t/sp.test:
      - Added test
    sql/item_func.cc:
      Bug#20777 Function w BIGINT UNSIGNED shows diff. behaviour with and without --ps-protocol
      
      - Stored procedures returning unsinged values returns signed values if
        text protocol is used. The reason is that the stored proceedure item
        Item_func_sp wasn't initializing the member variables properly based
        on the information contained in the associated result field.
      - The patch is to upon field-item association, ::fix_fields, initialize
        the member variables in appropriate order.
      - Field type of an Item_func_sp was hard coded to MYSQL_TYPE_VARCHAR.
        This is changed to to return the type of the actual result field.
      - Member function name sp_result_field was refactored to the more 
        appropriate init_result_field.
      - Member function name find_and_check_access was refactored to 
        sp_check_access.
    sql/item_func.h:
      Bug#20777 Function w BIGINT UNSIGNED shows diff. behaviour with and without --ps-protocol
      
      - Stored procedures returning unsinged values returns signed values if
        text protocol is used. The reason is that the stored proceedure item
        Item_func_sp wasn't initializing the member variables properly based
        on the information contained in the associated result field.
      - The patch is to upon field-item association, ::fix_fields, initialize
        the member variables in appropriate order.
      - Field type of an Item_func_sp was hard coded to MYSQL_TYPE_VARCHAR.
        This is changed to to return the type of the actual result field.
      - Member function name sp_result_field was refactored to the more 
        appropriate init_result_field.
      - Member function name find_and_check_access was refactored to 
        sp_check_access.
    ffc605aa
sp.test 145 KB