VistaDB 6
VistaDB Namespace / VistaDBType Enumeration


VistaDBType Enumeration
VistaDB 4 data types
Syntax
'Declaration
 
Public Enum VistaDBType 
   Inherits System.Enum
 
'Usage
 
Dim instance As VistaDBType
Members
MemberDescription
BigIntSystem.Int64.

64-bit signed integer.

Corresponding to SqlDbType.BigInt
BinarySystem.Byte[].

Fixed length binary data with a maximum length of 8000 bytes. Storage is inside the record

Corresponding to SqlDbType.Binary
BitSystem.Boolean.

Boolean value that can be true, false, or null.

Corresponding to SqlDbType.Bit
CharSystem.String. Char(x)

Fixed length character data with length of N characters. N must be a value from 1 through 8192. Storage size is N bytes of the data converted from Unicode string to non-Unicode character array.

DateSystem.DateTime.

A date only. From Jan 1, 0001 to Dec 31, 9999. Stored internally as a DateTime at midnight.

DateTimeSystem.DateTime.

Same as the SQL Server type DateTime2 (a .NET DateTime). Internal storage of this data type is 8 bytes. Date and time data ranging and accuracy are respective System.DateTime ranging and accuracy

Corresponding to SqlDbType.DateTime2
DateTime2System.DateTime.

Internal storage of this data type is 8 bytes. Date and time data ranging and accuracy are respective System.DateTime ranging and accuracy

Corresponding to SqlDbType.DateTime2
DateTimeOffsetSystem.DateTimeOffset.

A DateTime and specific timezone offset.

DecimalSystem.Decimal 128-bit (16-byte) integer scaled by a variable power of 10. Enumeration VistaDBType System.Data.SqlDbType.Decimal
FloatSystem.Double A double-precision (64-bit) floating-point number within the range of -1.79E +308 through 1.79E +308. Corresponding to SqlDbType.Float
ImageSystem.Byte[].

Variable length binary data with a maximum length of 134213632 bytes multiplied by database page size expressed in kilobytes (1 through 16). Actual data is outside the record (extended row data).

Corresponding to SqlDbType.Image
IntSystem.Int32.

32-bit signed integer.

Corresponding to SqlDbType.Int
MoneySystem.Decimal.

Signed 64-bit (8-byte) integers with scaling factor '4'. Store 8 bytes Relies on .Net Decimal type with fixed scaling factor

Corresponding to SqlDbType.Money
NCharSystem.String. NChar(x)

Fixed length Unicode character data of N characters. N must be a value from 1 through 8192. Storage size is two times N bytes

Corresponding to SqlDbType.NChar
NTextSystem.String.

Variable length Unicode character data with no explicit length. Storage is outside the record (extended type). Storage data is Unicode character array. Maximum length is 67106816 characters multiplied by database file page size expressed in kilobytes (1 through 16).

Corresponding to SqlDbType.NText
NVarCharSystem.String. NVarchar(x)

Variable length character data with length of N characters. N must be a value from 1 through 8192. Storage size, in bytes, is two times the number of characters entered. The data entered can be 0 characters in length. NVarchar data are stored inside the record.

Corresponding to SqlDbType.NVarChar
RealSystem.Single.

A floating point number within the range of -3.40E +38 through 3.40E +38.

Corresponding to SqlDbType.Real
SmallDateTimeSystem.DateTime.

Date and time data ranging in value from January 1, 1900 0:00 to November 30, 4451 1:19 PM an accuracy of one minute. Internal storage of this data type is 4 bytes

Corresponding to SqlDbType.SmallDateTime
SmallIntSystem.Int16.

16-bit signed integer.

Corresponding to SqlDbType.SmallInt
SmallMoneySystem.Decimal.

Signed 32-bit (4-byte) integers with scaling factor '4'. Store 4 bytes. Same as Currency but with less dynamic borders from -214,748.3648 through +214,748.3647

Corresponding to SqlDbType.SmallMoney
TextSystem.String.

Variable length character data with no explicit length. Storage is outside the record (extended type). Storage data is non-Unicode character array. Maximum length is 134213632 characters multiplied by database file page size expressed in kilobytes (1 throw 16).

Corresponding to SqlDbType.Text
TimeSystem.Timespan.

Time of day with a precision of 100 nanoseconds. Stored internally as a timespan since midnight.

TimestampSystem.Int64.

64-bit signed integer.

Automatically generated binary numbers, which are guaranteed to be unique within a database. This datatype does not store date or time information.

Corresponding to SqlDbType.TimeStamp

This is from the SQL Server docs: Is a data type that exposes automatically generated, unique binary numbers within a database. timestamp is generally used as a mechanism for version-stamping table rows. The storage size is 8 bytes. The timestamp data type is just an incrementing number and does not preserve a date or a time. To record a date or time, use a DateTime data type.

We use a 64 bit integer which is functionally the same as an 8 byte binary value. 8 binary bytes (8 bits each) is a 64 bit value. We visually show it to the user differently in the Data Builder than how Microsoft does. The SQL Server management studio shows the TIMESTAMP as BINARY data, we show the actual value. We use a single 64 bit value to make comparisons faster, rather than comparing each 8 bit value across 8 bytes.

TinyIntSystem.Byte.

8-bit unsigned integer.

Corresponding to SqlDbType.TinyInt
UninitializedUninitialized is used internally to indicate when a VistaDBType has not yet been set to anything.
UniqueIdentifierSystem.Guid.

A globally unique identifier (or GUID). Storage is inside the record

Corresponding to SqlDbType.UniqueIdentifier
UnknownReserved
VarBinarySystem.Byte[].

Varying length binary data with a maximum length of 800 bytes. Storage is inside the record

Corresponding to SqlDbType.VarBinary
VarCharSystem.String. Varchar(x)

Variable length character data with length of N characters. N must be a value from 1 through 8192. Storage size is the actual length in bytes of the data entered and converted from Unicode string to non-Unicode character array, not a fixed size. The data entered can be 0 characters in length. Varchar data are stored inside the record.

Corresponding to SqlDbType.VarChar
Remarks
The only SQL Server 2005 type not currently supported natively is the XML column type. This is due to the way that SQL Server allows for XPath queries to be executed against the XML columns. We plan to add support for this at a later time. (That was before GibraltarSoftware. No longer currently planned. -RSP) .Net Decimal types are different than Sql Server (see the Decimal column). SQL Server 2008 types for date and time are planned for 4.x. (New types implemented in 5.0)
Inheritance Hierarchy

System.Object
   System.ValueType
      System.Enum
         VistaDB.VistaDBType

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also