列表的这个DDL导致id_和name_字段的CLOB。
我怎样才能获得VARCHAR?
snappy> CREATE TABLE EXAMPLE_COLUMN_TABLE (
id_ VARCHAR(64),
name_ VARCHAR(128),
time_ TIMESTAMP,
number_ INTEGER
)
USING column
OPTIONS(PARTITION_BY 'time_', buckets '113', PERSISTENT 'ASYNCHRONOUS');
答案 0 :(得分:0)
不幸的是,这是由于Spark SQL中缺少VARCHAR类型。因此,我们将其转换为“字符串”,它在我们的数据字典中成为CLOB。 无论如何,这将在即将发布的版本中得到解决。 VARCHAR将完全兑现。而且,字符串类型实际上将变为具有未指定长度的VARCHAR。
目前,你能使用CAST功能吗?
if($_REQUEST['cityCode'] != ''){
$_SESSION['Cri_locations'] = $_REQUEST["s"];
$_SESSION['Cri_DateFrom'] = $_REQUEST["startDate"];
$_SESSION['Cri_DateTo'] = $_REQUEST["endDate"];
$what_to_search_id =str_replace("AREA-","",$_REQUEST["cityCode"]);
$total_adults =0;
$total_childs =0;
$child_ages =0;
$no_of_room =0;
for($i=1;$i<=$_REQUEST["Cri_noofRooms"];$i++){
$check_adults =$_REQUEST['adults-r'.$i.''];
if($check_adults>0){
$adults =$_REQUEST['adults-r'.$i.''];
$childs =$_REQUEST['childs-r'.$i.''];
$childAge =$_REQUEST['childAge-r'.$i.''];
$packs_arr[] =array('adults'=>$adults,'childs'=>$childs,'childAge'=>$childAge);
$total_adults =$total_adults+$adults;
$total_childs =$total_childs+$childs;
$child_ages =$child_ages+$childAge;//fatal-error-unsupported-operand-types accours here pls help
$no_of_room =$no_of_room+1;
}
}