Enum NpgsqlDbType
- Namespace
- NpgsqlTypes
- Assembly
- Npgsql.dll
Represents a PostgreSQL data type that can be written or read to the database. Used in places such as NpgsqlDbType to unambiguously specify how to encode or decode values.
public enum NpgsqlDbType
Fields
[Obsolete("The PostgreSQL abstime time is obsolete.")] Abstime = 33
Corresponds to the obsolete PostgreSQL "abstime" type.
See https://www.postgresql.org/docs/current/static/datatype-datetime.html
Array = -2147483648
Corresponds to the PostgreSQL "array" type, a variable-length multidimensional array of another type. This value must be combined with another value from NpgsqlDbType via a bit OR (e.g. NpgsqlDbType.Array | NpgsqlDbType.Integer)
See https://www.postgresql.org/docs/current/static/arrays.html
BigIntMultirange = 536870913
Corresponds to the PostgreSQL "int8multirange" type.
BigIntRange = 1073741825
Corresponds to the PostgreSQL "int8range" type.
Bigint = 1
Corresponds to the PostgreSQL 8-byte "bigint" type.
See https://www.postgresql.org/docs/current/static/datatype-numeric.html
Bit = 25
Corresponds to the PostgreSQL "bit" type.
See https://www.postgresql.org/docs/current/static/datatype-bit.html
Boolean = 2
Corresponds to the PostgreSQL "boolean" type.
See https://www.postgresql.org/docs/current/static/datatype-boolean.html
Box = 3
Corresponds to the PostgreSQL geometric "box" type.
See https://www.postgresql.org/docs/current/static/datatype-geometric.html
Bytea = 4
Corresponds to the PostgreSQL "bytea" type, holding a raw byte string.
See https://www.postgresql.org/docs/current/static/datatype-binary.html
Char = 6
Corresponds to the PostgreSQL "char(n)" type.
See https://www.postgresql.org/docs/current/static/datatype-character.html
Cid = 43
Corresponds to the PostgreSQL "cid" type, an internal command identifier.
See https://www.postgresql.org/docs/current/static/datatype-oid.html
Cidr = 44
Corresponds to the PostgreSQL "cidr" type, a field storing an IPv4 or IPv6 network.
See https://www.postgresql.org/docs/current/static/datatype-net-types.html
Circle = 5
Corresponds to the PostgreSQL geometric "circle" type.
See https://www.postgresql.org/docs/current/static/datatype-geometric.html
Citext = 51
Corresponds to the PostgreSQL "citext" type for the citext module.
See https://www.postgresql.org/docs/current/static/citext.html
Date = 7
Corresponds to the PostgreSQL "date" type.
See https://www.postgresql.org/docs/current/static/datatype-datetime.html
DateMultirange = 536870919
Corresponds to the PostgreSQL "datemultirange" type.
DateRange = 1073741831
Corresponds to the PostgreSQL "daterange" type.
Double = 8
Corresponds to the PostgreSQL 8-byte floating-point "double" type.
See https://www.postgresql.org/docs/current/static/datatype-numeric.html
Geography = 55
The geography (geodetic) type for PostgreSQL spatial extension PostGIS.
Geometry = 50
The geometry type for PostgreSQL spatial extension PostGIS.
Hstore = 37
Corresponds to the PostgreSQL "hstore" type, a dictionary of string key-value pairs.
See https://www.postgresql.org/docs/current/static/hstore.html
Inet = 24
Corresponds to the PostgreSQL "inet" type.
See https://www.postgresql.org/docs/current/static/datatype-net-types.html
Int2Vector = 52
Corresponds to the PostgreSQL internal "int2vector" type.
Integer = 9
Corresponds to the PostgreSQL 4-byte "integer" type.
See https://www.postgresql.org/docs/current/static/datatype-numeric.html
IntegerMultirange = 536870921
Corresponds to the PostgreSQL "int4multirange" type.
IntegerRange = 1073741833
Corresponds to the PostgreSQL "int4range" type.
InternalChar = 38
Corresponds to the PostgreSQL "char" type.
This is an internal field and should normally not be used for regular applications.
See https://www.postgresql.org/docs/current/static/datatype-text.html
Interval = 30
Corresponds to the PostgreSQL "interval" type.
See https://www.postgresql.org/docs/current/static/datatype-datetime.html
Json = 35
Corresponds to the PostgreSQL "json" type, a field storing JSON in text format.
See https://www.postgresql.org/docs/current/static/datatype-json.html
JsonPath = 57
Corresponds to the PostgreSQL "jsonpath" type, a field storing JSON path in text format. format.
Supported since PostgreSQL 12. See https://www.postgresql.org/docs/current/datatype-json.html#DATATYPE-JSONPATH
Jsonb = 36
Corresponds to the PostgreSQL "jsonb" type, a field storing JSON in an optimized binary. format.
Supported since PostgreSQL 9.4. See https://www.postgresql.org/docs/current/static/datatype-json.html
LQuery = 61
The PostgreSQL lquery type for PostgreSQL extension ltree
See https://www.postgresql.org/docs/current/static/ltree.html
LSeg = 11
Corresponds to the PostgreSQL geometric "lseg" type.
See https://www.postgresql.org/docs/current/static/datatype-geometric.html
LTree = 60
The PostgreSQL ltree type, each value is a label path "a.label.tree.value", forming a tree in a set.
See https://www.postgresql.org/docs/current/static/ltree.html
LTxtQuery = 62
The PostgreSQL ltxtquery type for PostgreSQL extension ltree
See https://www.postgresql.org/docs/current/static/ltree.html
Line = 10
Corresponds to the PostgreSQL geometric "line" type.
See https://www.postgresql.org/docs/current/static/datatype-geometric.html
MacAddr = 34
Corresponds to the PostgreSQL "macaddr" type, a field storing a 6-byte physical address.
See https://www.postgresql.org/docs/current/static/datatype-net-types.html
MacAddr8 = 54
Corresponds to the PostgreSQL "macaddr8" type, a field storing a 6-byte or 8-byte physical address.
See https://www.postgresql.org/docs/current/static/datatype-net-types.html
Money = 12
Corresponds to the PostgreSQL "money" type.
See https://www.postgresql.org/docs/current/static/datatype-money.html
Multirange = 536870912
Corresponds to the PostgreSQL "multirange" type, continuous range of values of specific type. This value must be combined with another value from NpgsqlDbType via a bit OR (e.g. NpgsqlDbType.Multirange | NpgsqlDbType.Integer)
Supported since PostgreSQL 14. See https://www.postgresql.org/docs/current/static/rangetypes.html
Name = 32
Corresponds to the PostgreSQL internal "name" type.
See https://www.postgresql.org/docs/current/static/datatype-character.html
Numeric = 13
Corresponds to the PostgreSQL arbitrary-precision "numeric" type.
See https://www.postgresql.org/docs/current/static/datatype-numeric.html
NumericMultirange = 536870925
Corresponds to the PostgreSQL "nummultirange" type.
NumericRange = 1073741837
Corresponds to the PostgreSQL "numrange" type.
Oid = 41
Corresponds to the PostgreSQL "oid" type.
See https://www.postgresql.org/docs/current/static/datatype-oid.html
Oidvector = 29
Corresponds to the PostgreSQL internal "oidvector" type.
See https://www.postgresql.org/docs/current/static/datatype-oid.html
Path = 14
Corresponds to the PostgreSQL geometric "path" type.
See https://www.postgresql.org/docs/current/static/datatype-geometric.html
PgLsn = 59
Corresponds to the PostgreSQL "pg_lsn" type, which can be used to store LSN (Log Sequence Number) data which is a pointer to a location in the WAL.
See: https://www.postgresql.org/docs/current/datatype-pg-lsn.html and https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=7d03a83f4d0736ba869fa6f93973f7623a27038a
Point = 15
Corresponds to the PostgreSQL geometric "point" type.
See https://www.postgresql.org/docs/current/static/datatype-geometric.html
Polygon = 16
Corresponds to the PostgreSQL geometric "polygon" type.
See https://www.postgresql.org/docs/current/static/datatype-geometric.html
Range = 1073741824
Corresponds to the PostgreSQL "range" type, continuous range of values of specific type. This value must be combined with another value from NpgsqlDbType via a bit OR (e.g. NpgsqlDbType.Range | NpgsqlDbType.Integer)
Supported since PostgreSQL 9.2. See https://www.postgresql.org/docs/current/static/rangetypes.html
Real = 17
Corresponds to the PostgreSQL floating-point "real" type.
See https://www.postgresql.org/docs/current/static/datatype-numeric.html
Refcursor = 23
Corresponds to the PostgreSQL "refcursor" type.
Regconfig = 56
Corresponds to the PostgreSQL "regconfig" type.
See https://www.postgresql.org/docs/current/static/datatype-textsearch.html
Regtype = 49
Corresponds to the PostgreSQL "regtype" type, a numeric (OID) ID of a type in the pg_type table.
Smallint = 18
Corresponds to the PostgreSQL 2-byte "smallint" type.
See https://www.postgresql.org/docs/current/static/datatype-numeric.html
Text = 19
Corresponds to the PostgreSQL "text" type.
See https://www.postgresql.org/docs/current/static/datatype-character.html
Tid = 53
Corresponds to the PostgreSQL "tid" type, a tuple id identifying the physical location of a row within its table.
Time = 20
Corresponds to the PostgreSQL "time" type.
See https://www.postgresql.org/docs/current/static/datatype-datetime.html
TimeTz = 31
Corresponds to the PostgreSQL "time with time zone" type.
See https://www.postgresql.org/docs/current/static/datatype-datetime.html
Timestamp = 21
Corresponds to the PostgreSQL "timestamp" type.
See https://www.postgresql.org/docs/current/static/datatype-datetime.html
TimestampMultirange = 536870933
Corresponds to the PostgreSQL "tsmultirange" type.
TimestampRange = 1073741845
Corresponds to the PostgreSQL "tsrange" type.
TimestampTz = 26
Corresponds to the PostgreSQL "timestamp with time zone" type.
See https://www.postgresql.org/docs/current/static/datatype-datetime.html
TimestampTzMultirange = 536870938
Corresponds to the PostgreSQL "tstzmultirange" type.
TimestampTzRange = 1073741850
Corresponds to the PostgreSQL "tstzrange" type.
TsQuery = 46
Corresponds to the PostgreSQL "tsquery" type.
See https://www.postgresql.org/docs/current/static/datatype-textsearch.html
TsVector = 45
Corresponds to the PostgreSQL "tsvector" type.
See https://www.postgresql.org/docs/current/static/datatype-textsearch.html
Unknown = 40
A special value that can be used to send parameter values to the database without specifying their type, allowing the database to cast them to another value based on context. The value will be converted to a string and send as text.
This value shouldn't ordinarily be used, and makes sense only when sending a data type unsupported by Npgsql.
Uuid = 27
Corresponds to the PostgreSQL "uuid" type.
See https://www.postgresql.org/docs/current/static/datatype-uuid.html
Varbit = 39
Corresponds to the PostgreSQL "varbit" type, a field storing a variable-length string of bits.
See https://www.postgresql.org/docs/current/static/datatype-boolean.html
Varchar = 22
Corresponds to the PostgreSQL "varchar" type.
See https://www.postgresql.org/docs/current/static/datatype-character.html
Xid = 42
Corresponds to the PostgreSQL "xid" type, an internal transaction identifier.
See https://www.postgresql.org/docs/current/static/datatype-oid.html
Xid8 = 64
Corresponds to the PostgreSQL "xid8" type, an internal transaction identifier.
See https://www.postgresql.org/docs/current/static/datatype-oid.html
Xml = 28
Corresponds to the PostgreSQL "xml" type.
See https://www.postgresql.org/docs/current/static/datatype-xml.html