create table seller(
seller_id int primary key,
seller_name text,
seller_email set<text>,
seller_address map<text>,
seller_phone list<text>,
product_id int,
product_title_text,
product_description text,
product_trackno int,
product_bidoption text,
bid_startdate date,
bid_closedate date,
bid_startprice int,
bid_withdrawdate date);
SyntaxException: line 1:110 mismatched input '>' expecting ',' (...<text>,
seller_address map<text[>],...)
要执行什么更改?
product_title_text,
这将起作用:
product_title text,
2)您还需要为地图集合提供两种类型。代替:
seller_address map<TEXT>,
这将起作用:
seller_address map<TEXT,TEXT>,
完整CQL:
create table seller(
seller_id int primary key,
seller_name text,
seller_email set<TEXT>,
seller_address map<TEXT,TEXT>,
seller_phone list<TEXT>,
product_id int,
product_title text,
product_description text,
product_trackno int,
product_bidoption text,
bid_startdate date,
bid_closedate date,
bid_startprice int,
bid_withdrawdate date);
而且,您真的只想按seller_id
查询此表吗?如果没有,您可能需要重新考虑主键定义。