Support Questions

Find answers, ask questions, and share your expertise

problem with putcassandraql NIFI processor and preparedstatement on cassandra insert using tinyint type

New Contributor

Hi there,

I refer to the template for ingestion on cassandra and the suggestion to set cql.N.type and cql.N.value type with update attribute and a prepared insert statement passed to a replacetext processor.

everything works great exluded a problem with a type tinyint that is replaced by null on the table

I attached the configuration of updateattribute

and this is my prepared statement

INSERT INTO keyspacexx.tablexxx (gics_gtw_id, gics_sensor_physical_id, gtw_alarm_id, alarm_timestamp, alarm_id, desc_sede, description, giotto_alarm_id, id_sede, in_esercizio, notes, realtime, severity, status, system_desc, system_id, username) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?);

thanks a lot



Super Guru

The cql.args.N.type attributes must be set to integers corresponding to the type of data. So for "int" fields, cql.args.1.type = 4, and for "tinyint", sql.args.10.type = -6.

Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.