lua-cassandra
lua-cassandra copied to clipboard
No decoder for type id 6
Hi, I am getting error "cassandra/buffer/init.lua:151: No decoder for type id 6" while running SELECT query (I am using plain Lua). When I did some trials with combination of selected columns I found the problem occurs when I am selecting columns with "decimal" type. I looked into the source code I found in file "cassandra/buffer/init.lua" line number 56, you have commented the "decimal 0x06". (Which I suppose is your future implementation plan). As the cql decimal is "Variable-precision decimal", I tried out by putting [cql_types.decimal] = "float" or [cql_types.decimal] = "int" but ended up getting 0. The Insert query is working (not sure this info helps). Could you please comment on this and fix the issue?
P.S: Thanks for this great library. Awesome work.
Hi,
Thanks for the report. Yes, this serializer was never written and I never thought of adding it. I think it has to do with the CQL decimal type, right?
The format is described in section 6.5 of the native protocol https://github.com/apache/cassandra/blob/trunk/doc/native_protocol_v3.spec