CQLSH客户端-模块'对象没有属性'parse_options [英] CQLSH client - module' object has no attribute 'parse_options

查看:48
本文介绍了CQLSH客户端-模块'对象没有属性'parse_options的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试通过CQLSH客户端访问我的Cassandra服务器,以导入巨大的CSV文件。我得到一个 module'对象没有属性'parse_options 错误。

I'm trying to access my Cassandra server through a CQLSH client to import a huge CSV file. I'm getting a module' object has no attribute 'parse_options error.

我运行以下命令命令:

cqlsh XXX.XXX.XX.XX XXXX --cqlversion="3.4.2" --execute="copy evolvdso.teste from '2016-10-26 15:25:10.csv' WITH DELIMITER =',' AND HEADER=TRUE --debug";

以下是调试和错误消息:

Starting copy of evolvdso.teste with columns ['ref_equip', 'date', 'load', 'ptd_assoc'].
Traceback (most recent call last):
  File "/usr/local/bin/cqlsh", line 1133, in onecmd
    self.handle_statement(st, statementtext)
  File "/usr/local/bin/cqlsh", line 1170, in handle_statement
    return custom_handler(parsed)
  File "/usr/local/bin/cqlsh", line 1834, in do_copy
    rows = self.perform_csv_import(ks, cf, columns, fname, opts)
  File "/usr/local/bin/cqlsh", line 1846, in perform_csv_import
    csv_options, dialect_options, unrecognized_options = copyutil.parse_options(self, opts)


AttributeError: 'module' object has no attribute 'parse_options'


推荐答案

当我从 pip install cqlsh使用 cqlsh 时遇到相同的问题/ code>。
尝试仅使用cassandra的工具 cqlsh

Has the same issue when I use cqlsh from pip install cqlsh. Try just use cassandra's tool cqlsh

sudo docker run -it cassandra / usr / bin / cqlsh

请参考 jira

这篇关于CQLSH客户端-模块'对象没有属性'parse_options的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆