Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
DB Access Module for Sybase User's Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

2.12 Error Messages: Contents of RWDBStatus

Sybase Open Client Client-Library distinguishes between errors originating from Sybase Adaptive Server Enterprise, and errors generated within Client-Library and CS-Library. The DB Interface Module honors the distinction by assigning error code serverError to errors from the server, and error code vendorLib to errors from Client-Library and CS-Library.

2.12.1 Reporting Errors from Client-Library and CS-Library

The format that RWDBStatus uses to report errors from Client-Library and CS-Library follows this paragraph. Notice that errors with a severity level zero are given special handling: the RWDBStatus::errorCode is set to RWDBStatus::ok, the rest of the RWDBStatus is populated, and an application's error handler (if any) is invoked. This means that SourcePro DB applications ignore these errors by default, but an application can process them if necessary. It also means that the error handler for the application should check vendorError2 (severity) before raising an exception.

2.12.2 Reporting Errors from Adaptive Server

The following format shows how RWDBStatus reports messages from Adaptive Server. Notice that RWDBStatus provides special handling for messages in which both severity and message number are 0, and for context switch messages (for example, Changed database context to master). When these messages occur, the RWDBStatus::errorCode is set to RWDBStatus::ok, the rest of the RWDBStatus is populated, and the application's error handler (if any) is invoked. Because errorCode is RWDBStatus::ok, SourcePro DB applications will ignore these errors by default. However, the error information itself is still accessible if the application needs to check it. The error handler should check vendorError2 (severity) before raising an exception.

All errors associated with the status are reported.



Previous fileTop of DocumentContentsNo linkNext file

Copyright © Rogue Wave Software, Inc. All Rights Reserved.

The Rogue Wave name and logo, and SourcePro, are registered trademarks of Rogue Wave Software. All other trademarks are the property of their respective owners.
Provide feedback to Rogue Wave about its documentation.