internal static extern OdbcReturnCode SQLSetEnvAttr(OdbcEnvironmentHandle environmentHandle, OdbcEnvironmentAttribute attribute, int value, int valueLengthShouldBeZero);
internal static void SetIntEnvironmentAttribute(OdbcEnvironmentHandle environmentHandle, OdbcEnvironmentAttribute attribute, int value) { if (environmentHandle == null) throw new ArgumentNullException("environmentHandle"); var result = NativeMethods.SQLSetEnvAttr(environmentHandle, attribute, value, 0); if ((result != OdbcReturnCode.Success) && (result != OdbcReturnCode.SuccessWithInfo)) { var ex = GetException(environmentHandle, string.Format("Unable to set ODBC environment attribute '{0:G}'.", attribute)); throw ex; } }