Enum odbc_api::handles::SqlResult[][src]

pub enum SqlResult<T> {
    Success(T),
    SuccessWithInfo(T),
    Error {
        function: &'static str,
    },
}
Expand description

Result of an ODBC function call. Variants hold the same meaning as the constants associated with SqlReturn. This type may hold results, but it is still the responsibility of the user to fetch and handle the diagnostics in case of an Error.

Variants

Success(T)

The function has been executed successfully.

Tuple Fields of Success

0: T
SuccessWithInfo(T)

The function has been executed successfully. There have been warnings.

Tuple Fields of SuccessWithInfo

0: T
Error

Function returned error state. Check diagnostics.

Fields of Error

function: &'static str

Name of the ODBC Api call which caused the error. This might help interpreting associatedif the error ODBC diagnostics if the error is bubbeld all the way up to the end users output, but the context is lost.

Implementations

Append a return value a successful to Result

Logs diagonstics of handle if variant is either Error or SuccessWithInfo.

True if variant is SqlResult::Error.

Applies f to any value wrapped in Success or SuccessWithInfo.

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.