开发者社区> 问答> 正文

sphinx配置sql_attr_multi

在sphinx.config 配置了       

sql_attr_multi = unit enact_id from query;\
                        select id,enact_id from mv_legal_enact_ref

但是报错:

ERROR: source 'legal': expected attr type ('uint' or 'timestamp' or 'bigint') in sql_attr_multi, got 'unit enact_id from query;            select id,enact_id from mv_legal_enact_ref'.
ERROR: index 'legal': failed to configure some of the sources, will not index.
请问如何配置呢???

展开
收起
huc_逆天 2020-05-28 09:16:48 655 0
1 条回答
写回答
取消 提交回答
  • sql_query = SELECT id,id as legal_id from mv_legal sql_attr_multi = uint enact_id from query;
    select legal_id,enact_id from mv_legal_enact_ref

    sql_query中的legal_id 和sql_attr_multi 中legal_id 对应即可

    2021-02-21 01:35:11
    赞同 展开评论 打赏
问答标签:
问答地址:
问答排行榜
最热
最新

相关电子书

更多
SQL Server 2017 立即下载
GeoMesa on Spark SQL 立即下载
原生SQL on Hadoop引擎- Apache HAWQ 2.x最新技术解密malili 立即下载