Contents Index stream synchronization parameter stream_parms synchronization parameter

UltraLite Embedded SQL User's Guide
  Synchronization Parameters Reference
    Synchronization parameters

stream_error synchronization parameter


Function 

Sets a structure to hold communications error reporting information.

Default 

The parameter has no default value, and must be explicitly set.

Description 

The stream_error field is a structure of type ul_stream_error.

typedef struct ss_error {
    ss_stream_id         stream_id;
    ss_stream_context    stream_context;
    ss_error_code        stream_error_code;
    asa_uint32           system_error_code;
    rp_char              *error_string;
    asa_uint32           error_string_length;
} ss_error, *p_ss_error;

The structure is defined in sserror.h, in the h subdirectory of your SQL Anywhere directory.

The ul_stream_error fields are as follows:

Usage 

Check for SQLE_COMMUNICATIONS_ERROR as follows:

ul_char  error_buff[ 100 ];
ul_synch_info info;
...
ULInitSynchInfo( &info );
info.stream_error.error_string = error_buff;
info.stream_error.error_string_length =
                   sizeof( error_buff );
...
ULSynchronize( &sqlca, &info )
if( SQLCODE == SQLE_COMMUNICATIONS_ERROR ){
    printf( error_buff );
...// more error handling here

Contents Index stream synchronization parameter stream_parms synchronization parameter