Skip to content

Primitive columns

Flavian Alexandru edited this page May 29, 2015 · 2 revisions

Build Status Coverage Status Maven Central Download

back to top

This is the list of available columns and how they map to C* data types. This also includes the newly introduced static columns in C* 2.0.6.

The type of a static column can be any of the allowed primitive Cassandra types. phantom won't let you mixin a non-primitive via implicit magic.

phantom columns Java/Scala type Cassandra type
BlobColumn java.nio.ByteBuffer blog
BigDecimalColumn scala.math.BigDecimal decimal
BigIntColumn scala.math.BigInt varint
BooleanColumn scala.Boolean boolean
DateColumn java.util.Date timestamp
DateTimeColumn org.joda.time.DateTime timestamp
DoubleColumn scala.Double double
EnumColumn scala.Enumeration text
FloatColumn scala.Float float
IntColumn scala.Int int
InetAddressColumn java.net.InetAddress inet
LongColumn scala.Long long
StringColumn java.lang.String text
UUIDColumn java.util.UUID uuid
TimeUUIDColumn java.util.UUID timeuuid
CounterColumn scala.Long counter
StaticColumn<type> <type> type static