Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » MobiLink - Client Administration » UltraLite Synchronization Parameters and Network Protocol options » Synchronization parameters for UltraLite

Send Download Acknowledgment synchronization parameter Next Page

Stream Error synchronization parameter


Provide a structure to hold communications error reporting information.

Syntax

The syntax varies depending on the API you use.

Applies To

This parameter applies only to C/C++ interfaces.

Allowed values

The parameter has no default value, and must be explicitly set using one of the supported fields. The ul_stream_error fields are as follows:

Remarks

UltraLite applications other than the UltraLite C++ Component receive communications error information as part of the Sync Result parameter. See Sync Result synchronization parameter.

The stream_error field is a structure of type ul_stream_error.

typedef struct ss_error_a {
    ss_stream_id         stream_id;
    ss_stream_context    stream_context;
    ss_error_code        stream_error_code;
    asa_uint32           system_error_code;
    char              *error_string;
    asa_uint32           error_string_length;
} ss_error_a, *p_ss_error_a;

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

Check for SQLE_COMMUNICATIONS_ERROR as follows:

Connection conn;
auto ul_synch_info_a info;
...
conn.InitSynchInfo( &info );
info.stream_error.error_string = error_buff;
info.stream_error.error_string_length =
                   sizeof( error_buff );
if( !conn.Synchronize( &synch_info ) ){
    if( SQLCODE == SQLE_COMMUNICATIONS_ERROR ){
        printf( error_buff );
    // more error handline here
See also