【发布时间】:2019-12-13 23:11:34
【问题描述】:
我正在尝试编写一个脚本来使用 python 列出 impala 中所有数据库中的所有表。我被困在 for 循环部分。
for i in databases.db:
cur.execute("show tables in", &i) #error occurs here
output11 = pd.DataFrame(cur.fetchall())
print(output11)
因为 impala 语法是 SHOW TABLES IN DATABASE_NAME HIVE 也是同样的问题。
【问题讨论】:
-
你不是在执行字符串中缺少
?吗?