Database.UInt8
Database
8-bit unsigned integer column type.
Reducers
Types
UInt8
type UInt8 = UInt88-bit unsigned integer column type.
Examples
type alias Row = { score : UInt8 }
access rows token
|> reduce (Database.UInt8.sum .score)Values
sum
sum : (row -> UInt8) -> Reducer row IntXCompute the sum of the relevant rows.
Examples
access rows token
|> reduce (Database.UInt8.sum .score)ands
ands : (row -> UInt8) -> Reducer row UInt8Compute the bitwise AND over the relevant rows.
Examples
access rows token
|> reduce (Database.UInt8.ands .flags)ors
ors : (row -> UInt8) -> Reducer row UInt8Compute the bitwise OR over the relevant rows.
Examples
access rows token
|> reduce (Database.UInt8.ors .flags)xors
xors : (row -> UInt8) -> Reducer row UInt8Compute the bitwise XOR over the relevant rows. Useful as a checksum for an unordered set of values.
Examples
access rows token
|> reduce (Database.UInt8.xors .flags)