简体   繁体   中英

Reading Cassandra Map in Node.js

I have table created using map in cassandra, Now i am trying to read the table from node.js and it returns object for the map, can i get the item count in a map and loop through it to get the items in the map?

table script create table workingteam (teamid bigint primary key, status map)

You did not post a lot of details. First you will need to study the object Cassandra sends you. Good way to start would be to convert it to the JSON format and dump to the output through log.

console.log("Cassandra sent: %j", object);

I'm guessing in this object you will find attributes like connection parameters, host, client etc, but also something iterative that will contain keys and values.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM