SqlBoolean Structure

Represents an integer value that is either 1 or 0 to be stored in or retrieved from a database.

Namespace:  System.Data.SqlTypes
Assembly:  System.Data (in System.Data.dll)

[SerializableAttribute]
public struct SqlBoolean : INullable, 
	IComparable, IXmlSerializable

The SqlBoolean type exposes the following members.

  NameDescription
Public methodSupported by the XNA FrameworkSqlBoolean(Boolean)Initializes a new instance of the SqlBoolean structure using the supplied Boolean value.
Public methodSupported by the XNA FrameworkSqlBoolean(Int32)Initializes a new instance of the SqlBoolean structure using the specified integer value.
Top

  NameDescription
Public propertySupported by the XNA FrameworkByteValueGets the value of the SqlBoolean structure as a byte.
Public propertySupported by the XNA FrameworkIsFalseIndicates whether the current Value is False.
Public propertySupported by the XNA FrameworkIsNullIndicates whether this SqlBoolean structure is null.
Public propertySupported by the XNA FrameworkIsTrueIndicates whether the current Value is True.
Public propertySupported by the XNA FrameworkValueGets the SqlBoolean structure's value. This property is read-only.
Top

  NameDescription
Public methodStatic memberSupported by the XNA FrameworkAndComputes the bitwise AND operation of two specified SqlBoolean structures.
Public methodSupported by the XNA FrameworkCompareTo(Object)Compares this SqlBoolean structure to a specified object and returns an indication of their relative values.
Public methodSupported by the XNA FrameworkCompareTo(SqlBoolean)Compares this SqlBoolean object to the supplied SqlBoolean object and returns an indication of their relative values.
Public methodSupported by the XNA FrameworkEquals(Object)Compares the supplied object parameter to the SqlBoolean. (Overrides ValueType.Equals(Object).)
Public methodStatic memberSupported by the XNA FrameworkEquals(SqlBoolean, SqlBoolean)Compares two SqlBoolean structures to determine whether they are equal.
Public methodSupported by the XNA FrameworkGetHashCodeReturns the hash code for this instance. (Overrides ValueType.GetHashCode().)
Public methodSupported by the XNA FrameworkGetTypeGets the Type of the current instance. (Inherited from Object.)
Public methodStatic memberSupported by the XNA FrameworkGetXsdTypeReturns the XML Schema definition language (XSD) of the specified XmlSchemaSet.
Public methodStatic memberSupported by the XNA FrameworkGreaterThanCompares two instances of SqlBoolean to determine whether the first is greater than the second.
Public methodStatic memberSupported by the XNA FrameworkGreaterThanOrEqualsCompares two instances of SqlBoolean to determine whether the first is greater than or equal to the second.
Public methodStatic memberSupported by the XNA FrameworkLessThanCompares two instances of SqlBoolean to determine whether the first is less than the second.
Public methodStatic memberSupported by the XNA FrameworkLessThanOrEqualsCompares two instances of SqlBoolean to determine whether the first is less than or equal to the second.
Public methodStatic memberSupported by the XNA FrameworkNotEqualsCompares two instances of SqlBoolean for equality.
Public methodStatic memberSupported by the XNA FrameworkOnesComplementPerforms a one's complement operation on the supplied SqlBoolean structures.
Public methodStatic memberSupported by the XNA FrameworkOrPerforms a bitwise OR operation on the two specified SqlBoolean structures.
Public methodStatic memberSupported by the XNA FrameworkParseConverts the specified String representation of a logical value to its SqlBoolean equivalent.
Public methodSupported by the XNA FrameworkToSqlByteConverts this SqlBoolean structure to SqlByte.
Public methodSupported by the XNA FrameworkToSqlDecimalConverts this SqlBoolean structure to SqlDecimal.
Public methodSupported by the XNA FrameworkToSqlDoubleConverts this SqlBoolean structure to SqlDouble.
Public methodSupported by the XNA FrameworkToSqlInt16Converts this SqlBoolean structure to SqlInt16.
Public methodSupported by the XNA FrameworkToSqlInt32Converts this SqlBoolean structure to SqlInt32.
Public methodSupported by the XNA FrameworkToSqlInt64Converts this SqlBoolean structure to SqlInt64.
Public methodSupported by the XNA FrameworkToSqlMoneyConverts this SqlBoolean structure to SqlMoney.
Public methodSupported by the XNA FrameworkToSqlSingleConverts this SqlBoolean structure to SqlSingle.
Public methodSupported by the XNA FrameworkToSqlStringConverts this SqlBoolean structure to SqlString.
Public methodSupported by the XNA FrameworkToStringConverts this SqlBoolean structure to a string. (Overrides ValueType.ToString().)
Public methodStatic memberSupported by the XNA FrameworkXorPerforms a bitwise exclusive-OR operation on the supplied parameters.
Top

  NameDescription
Public operatorStatic memberSupported by the XNA FrameworkBitwiseAndComputes the bitwise AND operation of two specified SqlBoolean structures.
Public operatorStatic memberSupported by the XNA FrameworkBitwiseOrComputes the bitwise OR of its operands.
Public operatorStatic memberSupported by the XNA FrameworkEqualityCompares two instances of SqlBoolean for equality.
Public operatorStatic memberSupported by the XNA FrameworkExclusiveOrPerforms a bitwise exclusive-OR (XOR) operation on the supplied parameters.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlBoolean to Boolean)Converts a SqlBoolean to a Boolean.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlByte to SqlBoolean)Converts the SqlByte parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlDecimal to SqlBoolean)Converts the SqlDecimal parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlDouble to SqlBoolean)Converts the SqlDouble parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlInt16 to SqlBoolean)Converts the SqlInt16 parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlInt32 to SqlBoolean)Converts the SqlInt32 parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlInt64 to SqlBoolean)Converts the SqlInt64 parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlMoney to SqlBoolean)Converts the SqlMoney parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlSingle to SqlBoolean)Converts the SqlSingle parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkExplicit(SqlString to SqlBoolean)Converts the SqlString parameter to a SqlBoolean structure.
Public operatorStatic memberSupported by the XNA FrameworkFalseThe false operator can be used to test the Value of the SqlBoolean to determine whether it is false.
Public operatorStatic memberSupported by the XNA FrameworkGreaterThanCompares two SqlBoolean structures to determine whether the first is greater than the second.
Public operatorStatic memberSupported by the XNA FrameworkGreaterThanOrEqualCompares two SqlBoolean structures to determine whether the first is greater than or equal to the second.
Public operatorStatic memberSupported by the XNA FrameworkImplicit(Boolean to SqlBoolean)Converts the supplied byte value to a SqlBoolean.
Public operatorStatic memberSupported by the XNA FrameworkInequalityCompares two instances of SqlBoolean to determine whether they are not equal.
Public operatorStatic memberSupported by the XNA FrameworkLessThanCompares two instances of SqlBoolean to determine whether the first is less than the second.
Public operatorStatic memberSupported by the XNA FrameworkLessThanOrEqualCompares two instances of SqlBoolean to determine whether the first is less than or equal to the second.
Public operatorStatic memberSupported by the XNA FrameworkLogicalNotPerforms a NOT operation on a SqlBoolean.
Public operatorStatic memberSupported by the XNA FrameworkOnesComplementPerforms a one's complement operation on the supplied SqlBoolean structures.
Public operatorStatic memberSupported by the XNA FrameworkTrueThe true operator can be used to test the Value of the SqlBoolean to determine whether it is true.
Top

  NameDescription
Public fieldStatic memberSupported by the XNA FrameworkFalseRepresents a false value that can be assigned to the Value property of an instance of the SqlBoolean structure.
Public fieldStatic memberSupported by the XNA FrameworkNullRepresents DBNull that can be assigned to this instance of the SqlBoolean structure.
Public fieldStatic memberSupported by the XNA FrameworkOneRepresents a one value that can be assigned to the ByteValue property of an instance of the SqlBoolean structure.
Public fieldStatic memberSupported by the XNA FrameworkTrueRepresents a true value that can be assigned to the Value property of an instance of the SqlBoolean structure.
Public fieldStatic memberSupported by the XNA FrameworkZeroRepresents a zero value that can be assigned to the ByteValue property of an instance of the SqlBoolean structure.
Top

  NameDescription
Explicit interface implemetationPrivate methodSupported by the XNA FrameworkIXmlSerializable.GetSchemaThis member supports the .NET Framework infrastructure and is not intended to be used directly from your code.
Explicit interface implemetationPrivate methodSupported by the XNA FrameworkIXmlSerializable.ReadXmlThis member supports the .NET Framework infrastructure and is not intended to be used directly from your code.
Explicit interface implemetationPrivate methodSupported by the XNA FrameworkIXmlSerializable.WriteXmlThis member supports the .NET Framework infrastructure and is not intended to be used directly from your code.
Top

Any non-zero value is interpreted as 1.

The key difference between a SqlBoolean structure and a standard Boolean value is that, where a standard Boolean has two possible values, true and false, a SqlBoolean structure has three possible values, True, False, or Null.

.NET Framework

Supported in: 4.5, 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft