previous | Table of Contents | next
Appendix

# Appendix A: Supported data types in `PyTables`

`IsDescription` subclasses supports a limited set of data types to define the table fields. Such a set is roughly the same than the types supported by the `numarray` package (see ) in Python, with the exception of the complex datatypes that are not supported yet.

These data types in table columns can be set through the use of the `Col` class and its descendants (see 4.11.2). You may find useful the table A as a quick reference to the complete set of supported data types in PyTables.

Table A.1: Data types supported by subclasses of `IsDescription` definitions.
Type Code | Description | C Type | Size (in bytes) | Python Counterpart
--- | --- | --- | --- | ---
Bool | boolean | unsigned char | 1 | Boolean
Int8 | 8-bit integer | signed char | 1 | Integer
UInt8 | 8-bit unsigned integer | unsigned char | 1 | Integer
Int16 | 16-bit integer | short | 2 | Integer
UInt16 | 16-bit unsigned integer | unsigned short | 2 | Integer
Int32 | integer | int | 4 | Integer
UInt32 | unsigned integer | unsigned int | 4 | Long
Int64 | 64-bit integer | long long | 8 | Long
UInt64 | unsigned 64-bit integer | unsigned long long | 8 | Long
Float32 | single-precision float | float | 4 | Float
Float64 | double-precision float | double | 8 | Float
CharType | arbitrary length string | char[] | * | String

previous | Table of Contents | next