pub trait Diagnostics: Handle {
// Provided methods
fn SQLGetDiagFieldA<A: Ident<Type = SQLSMALLINT>, T>(
&self,
RecNumber: NonZeroI16,
DiagIdentifier: A,
DiagInfoPtr: Option<&mut T>,
StringLengthPtr: Option<&mut MaybeUninit<T::StrLen>>,
) -> SQLRETURN
where T: AttrGet<A> + Ansi + ?Sized + DiagField<Self, A>,
MaybeUninit<T::StrLen>: StrLen<SQLSMALLINT> { ... }
fn SQLGetDiagFieldW<A: Ident<Type = SQLSMALLINT>, T>(
&self,
RecNumber: NonZeroI16,
DiagIdentifier: A,
DiagInfoPtr: Option<&mut T>,
StringLengthPtr: Option<&mut MaybeUninit<T::StrLen>>,
) -> SQLRETURN
where T: AttrGet<A> + Unicode + ?Sized + DiagField<Self, A>,
MaybeUninit<T::StrLen>: StrLen<SQLSMALLINT> { ... }
fn SQLGetDiagRecA(
&self,
RecNumber: NonZeroI16,
SQLState: &mut MaybeUninit<SQLSTATE<SQLCHAR>>,
NativeErrorPtr: &mut impl AsMutPtr<SQLINTEGER>,
MessageText: &mut OdbcStr<MaybeUninit<SQLCHAR>>,
TextLengthPtr: &mut impl AsMutPtr<SQLSMALLINT>,
) -> SQLRETURN { ... }
fn SQLGetDiagRecW(
&self,
RecNumber: NonZeroI16,
SQLState: &mut MaybeUninit<SQLSTATE<SQLWCHAR>>,
NativeErrorPtr: &mut impl AsMutPtr<SQLINTEGER>,
MessageText: &mut OdbcStr<MaybeUninit<SQLWCHAR>>,
TextLengthPtr: &mut impl AsMutPtr<SQLSMALLINT>,
) -> SQLRETURN { ... }
}Provided Methods§
Sourcefn SQLGetDiagFieldA<A: Ident<Type = SQLSMALLINT>, T>(
&self,
RecNumber: NonZeroI16,
DiagIdentifier: A,
DiagInfoPtr: Option<&mut T>,
StringLengthPtr: Option<&mut MaybeUninit<T::StrLen>>,
) -> SQLRETURNwhere
T: AttrGet<A> + Ansi + ?Sized + DiagField<Self, A>,
MaybeUninit<T::StrLen>: StrLen<SQLSMALLINT>,
fn SQLGetDiagFieldA<A: Ident<Type = SQLSMALLINT>, T>(
&self,
RecNumber: NonZeroI16,
DiagIdentifier: A,
DiagInfoPtr: Option<&mut T>,
StringLengthPtr: Option<&mut MaybeUninit<T::StrLen>>,
) -> SQLRETURNwhere
T: AttrGet<A> + Ansi + ?Sized + DiagField<Self, A>,
MaybeUninit<T::StrLen>: StrLen<SQLSMALLINT>,
Returns the current value of a field of a record of the diagnostic data structure (associated with a specified handle) that contains error, warning, and status information.
For complete documentation on SQLGetDiagFieldA, see API reference.
§Returns
SQL_SUCCESS, SQL_SUCCESS_WITH_INFO, SQL_ERROR, SQL_INVALID_HANDLE, or SQL_NO_DATA.
Sourcefn SQLGetDiagFieldW<A: Ident<Type = SQLSMALLINT>, T>(
&self,
RecNumber: NonZeroI16,
DiagIdentifier: A,
DiagInfoPtr: Option<&mut T>,
StringLengthPtr: Option<&mut MaybeUninit<T::StrLen>>,
) -> SQLRETURNwhere
T: AttrGet<A> + Unicode + ?Sized + DiagField<Self, A>,
MaybeUninit<T::StrLen>: StrLen<SQLSMALLINT>,
fn SQLGetDiagFieldW<A: Ident<Type = SQLSMALLINT>, T>(
&self,
RecNumber: NonZeroI16,
DiagIdentifier: A,
DiagInfoPtr: Option<&mut T>,
StringLengthPtr: Option<&mut MaybeUninit<T::StrLen>>,
) -> SQLRETURNwhere
T: AttrGet<A> + Unicode + ?Sized + DiagField<Self, A>,
MaybeUninit<T::StrLen>: StrLen<SQLSMALLINT>,
Returns the current value of a field of a record of the diagnostic data structure (associated with a specified handle) that contains error, warning, and status information.
For complete documentation on SQLGetDiagFieldW, see API reference.
§Returns
SQL_SUCCESS, SQL_SUCCESS_WITH_INFO, SQL_ERROR, SQL_INVALID_HANDLE, or SQL_NO_DATA.
Sourcefn SQLGetDiagRecA(
&self,
RecNumber: NonZeroI16,
SQLState: &mut MaybeUninit<SQLSTATE<SQLCHAR>>,
NativeErrorPtr: &mut impl AsMutPtr<SQLINTEGER>,
MessageText: &mut OdbcStr<MaybeUninit<SQLCHAR>>,
TextLengthPtr: &mut impl AsMutPtr<SQLSMALLINT>,
) -> SQLRETURN
fn SQLGetDiagRecA( &self, RecNumber: NonZeroI16, SQLState: &mut MaybeUninit<SQLSTATE<SQLCHAR>>, NativeErrorPtr: &mut impl AsMutPtr<SQLINTEGER>, MessageText: &mut OdbcStr<MaybeUninit<SQLCHAR>>, TextLengthPtr: &mut impl AsMutPtr<SQLSMALLINT>, ) -> SQLRETURN
Returns the current values of multiple fields of a diagnostic record that contains error, warning, and status information. Unlike SQLGetDiagField, which returns one diagnostic field per call, SQLGetDiagRec returns several commonly used fields of a diagnostic record, including the SQLSTATE, the native error code, and the diagnostic message text.
For complete documentation on SQLGetDiagRecA, see API reference.
§Returns
SQL_SUCCESS, SQL_SUCCESS_WITH_INFO, SQL_ERROR, or SQL_INVALID_HANDLE.
Sourcefn SQLGetDiagRecW(
&self,
RecNumber: NonZeroI16,
SQLState: &mut MaybeUninit<SQLSTATE<SQLWCHAR>>,
NativeErrorPtr: &mut impl AsMutPtr<SQLINTEGER>,
MessageText: &mut OdbcStr<MaybeUninit<SQLWCHAR>>,
TextLengthPtr: &mut impl AsMutPtr<SQLSMALLINT>,
) -> SQLRETURN
fn SQLGetDiagRecW( &self, RecNumber: NonZeroI16, SQLState: &mut MaybeUninit<SQLSTATE<SQLWCHAR>>, NativeErrorPtr: &mut impl AsMutPtr<SQLINTEGER>, MessageText: &mut OdbcStr<MaybeUninit<SQLWCHAR>>, TextLengthPtr: &mut impl AsMutPtr<SQLSMALLINT>, ) -> SQLRETURN
Returns the current values of multiple fields of a diagnostic record that contains error, warning, and status information. Unlike SQLGetDiagField, which returns one diagnostic field per call, SQLGetDiagRec returns several commonly used fields of a diagnostic record, including the SQLSTATE, the native error code, and the diagnostic message text.
For complete documentation on SQLGetDiagRecW, see API reference.
§Returns
SQL_SUCCESS, SQL_SUCCESS_WITH_INFO, SQL_ERROR, or SQL_INVALID_HANDLE.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.